jquery tab mouseover 特效
2014-03-09 22:12
573 查看
<!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">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<head>
<title>jQuery</title>
<style>
ul, li{list-style:none;}
#linTab ul li{float:left;width:50px;}
.clearBoth{clear:both;}
.on{display:block;}
.none{display:none;}
</style>
<script src="./jquery/jquery-1.7.1.min.js"></script>
<script>
$(document).ready(function(){
$change_li = $(".linListTab li");
$change_li.each(function(i){
$(this).mouseover(function(){
$(this).addClass("on").siblings().removeClass("on");
$(".linBoxListContent dl").eq(i).show().siblings().hide();
});
});
});
</script>
</head>
<body>
<div id="linTab">
<div class="linListTab">
<ul>
<li class="on"><a href="javascript:void(0)">第一</a></li>
<li><a href="javascript:void(0)">第二</a></li>
<li><a href="javascript:void(0)">第三</a></li>
</ul>
<br class="clearBoth" />
</div>
<div class="linBoxListContent">
<dl>
<dd>1111</dd>
</dl>
<dl class="none">
<dd>2222</dd>
</dl>
<dl class="none">
<dd>3333</dd>
</dl>
</div>
</div>
</body>
</html>
<html xmlns="http://www.w3.org/1999/xhtml">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<head>
<title>jQuery</title>
<style>
ul, li{list-style:none;}
#linTab ul li{float:left;width:50px;}
.clearBoth{clear:both;}
.on{display:block;}
.none{display:none;}
</style>
<script src="./jquery/jquery-1.7.1.min.js"></script>
<script>
$(document).ready(function(){
$change_li = $(".linListTab li");
$change_li.each(function(i){
$(this).mouseover(function(){
$(this).addClass("on").siblings().removeClass("on");
$(".linBoxListContent dl").eq(i).show().siblings().hide();
});
});
});
</script>
</head>
<body>
<div id="linTab">
<div class="linListTab">
<ul>
<li class="on"><a href="javascript:void(0)">第一</a></li>
<li><a href="javascript:void(0)">第二</a></li>
<li><a href="javascript:void(0)">第三</a></li>
</ul>
<br class="clearBoth" />
</div>
<div class="linBoxListContent">
<dl>
<dd>1111</dd>
</dl>
<dl class="none">
<dd>2222</dd>
</dl>
<dl class="none">
<dd>3333</dd>
</dl>
</div>
</div>
</body>
</html>
相关文章推荐
- JQUERY mouseover事件指针穿过子元素同样会触发 .
- 原生js与jQuery实现简单的tab切换特效对比
- Highlight On Mouseover Effect With JQuery
- js jquery tab,鼠标悬浮等特效 搜集以后备用......
- 原生js与jQuery实现简单的tab切换特效对比
- jQuery mouseover弹出title以及弹出大图的例子
- JQuery-EasyUI Datagrid数据行鼠标悬停/离开事件(onMouseOver/onMouseOut)
- jQuery插件Mouse Over Animation for Text制作文字透镜、波浪和透明效果
- tytabs.jquery.min.js实例,渐变的TAB选项卡特效
- Jquery mouseover 使用 ---图片放大功能
- Jquery 简单的Tab选项卡特效
- jQuery 事件 keypress click mouseover blur load
- jQuery:mouseover and Increase the Size of an Image
- jQuery mouseover与mouseenter,mouseout与mouseleave的区别
- jquery mouseover与mouseenter区别
- jQuery mouseover与mouseenter,mouseout与mouseleave的区别
- jQuery实现TAB选项卡切换特效简单演示
- 一个简单的Tab平滑切换特效jquery代码,没有做最大效率优化
- jQuery:mouseover and Increase the Size of an Image
- jQuery实现TAB选项卡切换特效简单演示