Jquery implements TAB effects that specify the default page size

  • 2020-03-26 21:30:26
  • OfStack

You can specify the default page size in your code
< img SRC = "border = 0 / / files.jb51.net/file_images/article/201310/201310161607251.gif? 201391616821 ">  
 
<div id="container" style="width:500px;"> 
<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"><a href="http://www.freejs.net/article_tabbiaoqian_29.html">jquery Implement simple Tab To switch the menu </a></div> 
<div id="fragment-2"><a href="http://www.freejs.net/article_jiaodiantu_56.html">jquery Focus figure  slideshow</a></div> 
<div id="fragment-3"> js And so on </div> 
</div> 

 
<script language="javascript"> 
$(function(){ 
//Make Tab menu directly, the default choice is the second item, and when switching the fade animation
$("#container > ul").tabs({fx:{opacity:"toggle",height:"toggle"}, selected:1}); 
}); 
</script> 

Notice that selected:1 above displays the second page for control by default

Related articles: