<script type="text/javascript">
var datas= {"image/00-03smail.JPG":["image/00-03.jpg","swelte","24"],"image/00-51smail.JPG":["image/00-51.jpg","yinger","21"],"01-01smail.JPG":["image/01-01.jpg","henkes","23"]};
function TrendsCreate()
{
//var div = document .createElement ("div");
for(var smailimg in datas )
{
var smailImg = document.createElement ("img");
smailImg.src = smailimg ;
smailImg .setAttribute ("imgaddress",datas[smailimg][0]);
smailImg .setAttribute ("Height",datas[smailimg][1]);
smailImg .setAttribute ("Name",datas[smailimg][2]);
smailImg .onmouseover= function (){
document.getElementById ("detailimg").src = this .getAttribute ("imgadress");
document.getElementById ("detailHeight").innerHTML =this .getAttribute ("Height");
document.getElementById ("detailName").innerHTML = this.getAttribute ("Name");
var div1 =document .getElementById ("detail");
div1.style.top = window.event.clientY;
div1.style.left = window.event.clientX;
div1.style.display ="";
};
smailImg .onmouseout = function (){
var div1 =document .getElementById ("detailimg");
div1.style.display ="none";
};
document .body .appendChild (smailImg );
//div1.appendChild (smailImg );
}
// document.body.appendChild (smailImg );
}
</script>
</head>
<body onload="TrendsCreate()">
<div id="detail" style ="position:absolute ;display:none ; border-style:inherit;">
<img src="" id ="detailimg"/>
<p id="detailHeight"></p>
<p id="detailName"></p>
</div>
</body>
</html>
|