<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
<script src="js/jquery-1.11.1.min.js"></script>
<script type="text/javascript">
$(function(){
$("ul li").click(function(){
var $index = $(this).index();
$(".wrap .split").each(function(index,element){
$(element).find(".img").eq($index).removeClass("hide").addClass("show").siblings(".show").removeClass("show").addClass("hide");
})
})
}
)
</script>
<style>
body{
margin: 0px;
padding: 0px;
}
.wrap{
width:1152px;
height:648px;
margin: 0px auto;
}
.wrap .split{
width:192px;
height:648px;
position:relative;
overflow: hidden;
float: left;
}
利用Jquery实现百叶窗效果
最新推荐文章于 2024-05-14 12:18:41 发布