标签:else slide www tle addclass lang display charset asc
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>jquery竖向简单有效导航菜单 -</title>
<link href="css/lanrenzhijia.css" type="text/css" rel="stylesheet" />
<script language="javascript" src="js/jquery.min.js"></script>
<script>
$(function(){
//菜单隐藏展开
var tabs_i=0
$(‘.vtitle‘).click(function(){
var _self = $(this);
var j = $(‘.vtitle‘).index(_self);
if( tabs_i == j ) return false; tabs_i = j;
$(‘.vtitle em‘).each(function(e){
if(e==tabs_i){
$(‘em‘,_self).removeClass(‘v01‘).addClass(‘v02‘);
}else{
$(this).removeClass(‘v02‘).addClass(‘v01‘);
}
});
$(‘.vcon‘).slideUp().eq(tabs_i).slideDown();
});
})
</script>
</head>
<body>
<div style="width:268px;margin:30px auto 0 auto;">
<div class="vtitle"><em class="v v02"></em>nav1</div>
<div class="vcon">
<ul class="vconlist clearfix">
<li class="select"><a href="javascript:;">李健</a></li>
<li><a href="javascript:;">张棋华</a></li>
<li><a href="javascript:;">吃屎啦</a></li>
</ul>
</div>
<div class="vtitle"><em class="v"></em>nav2</div>
<div class="vcon" style="display: none;">
<ul class="vconlist clearfix">
<li><a href="javascript:;">content</a></li>
<li><a href="javascript:;">content</a></li>
<li><a href="javascript:;">content</a></li>
</ul>
</div>
<div class="vtitle"><em class="v"></em>nav3</div>
<div class="vcon" style="display: none;">
<ul class="vconlist clearfix">
<li><a href="javascript:;">content</a></li>
<li><a href="javascript:;">content</a></li>
<li><a href="javascript:;">content</a></li>
</ul>
</div>
</div>
</body>
</html>
标签:else slide www tle addclass lang display charset asc
原文地址:http://www.cnblogs.com/jrsflak/p/7801659.html