日期:2014-05-16 浏览次数:20816 次
<html>
<head>
<style type="text/css">
.products-normal li{position:relative; width:150px; height:220px; float:left;}
.product-small-info{position:relative; z-index:1;}
.product-big-info{position:absolute; z-index:99999; display:none; top:0px; left:0px;}
</style>
</head>
<body>
<div>
<ul class="products-normal">
<li>
<div class="product-small-info" onmouseover="showBigPic('product1')" onmouseout="hideBigPic('product1')">
<img src="./Public/Images/tmp3_120x120.jpg"/>
</div>
<div class="product-big-info" id="product1">
<img src="./Public/Images/tmp3_220x220.jpg"/>
</div>
</li>
<li>
<div class="product-small-info" onmouseover="showBigPic('product2')" onmouseout="hideBigPic('product2')">
<img src="./Public/Images/tmp_120x120.jpg"/>
</div>
<div class="product-big-info" id="product2">
<img src="./Public/Images/tmp3_220x220.jpg"/>
</div>
</li>
</ul>
</div>
<script type="text/javascript">
function showBigPic(liid){
var liobj = document.getElementById(liid);
liobj.style.display="block";
}
function hideBigPic(liid){
var liobj = document.getElementById(liid);
liobj.style.display="none";
}
</script>
</body>
</html>
<ul class="products-normal">
<li onmouseover="showBigPic('product1')" onmouseout="hideBigPic('product1')">
<div class="product-small-info">
<img src="./Public/Images/tmp3_120x120.jpg"/>
</div>
<div class="product-big-info" id="product1">
<img src="./Public/Images/tmp3_220x220.jpg"/>
</div>