在使用ui tab时,不要在整个tab容器的DIV(id="example")和每个tab页的DIV(id="fragment-1/2/3")中使用style,JQUERY会重
置这些地方的style,class属性不受影响。
例:
- <div id="example" class="flora">
- <ul>
- <li><a href="#fragment-1"><span>One</span></a></li>
- <li><a href="#fragment-2"><span>Two</span></a></li>
- <li><a href="#fragment-3"><span>Three</span></a></li>
- </ul>
- <div id="fragment-1">
- <p>First tab is active by default:</p>
- <pre><code>$('#example > ul').tabs();</code></pre>
- </div>
- <div id="fragment-2">
- Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut
- laoreet dolore magna aliquam erat volutpat.
- Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut
- laoreet dolore magna aliquam erat volutpat.
- </div>
- <div id="fragment-3">
- Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut
- laoreet dolore magna aliquam erat volutpat.
- Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut
- laoreet dolore magna aliquam erat volutpat.
- Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut
- laoreet dolore magna aliquam erat volutpat.
- </div>
- </div>
ikmb@163.com