点击图片从而改变网页背景图片 - 网页特效代码|:<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"> <title>网页特效代码|JsCode.CN|---点击图片从而改变网页背景图片</title> </head>
<body>
<script language="JavaScript1.2">
<!-- function tile(){ if (!document.all) return var source=event.srcElement if (source.tagName=="IMG") document.body.style.backgroundImage="url("+source.src+")" } function restore(){
document.body.style.backgroundImage='' } document.body.ondblclick=restore --> </script> </p> <p align="center"><span class="bgimages" onClick="tile();event.cancelBubble=true"> <img src="http://www./images/IndexIron01.gif" height=96 width=96 border=2> <img src="http://www./images/IndexIron02.gif" height=96 width=96 border=2><br> <img src="http://www./images/IndexIron03.gif" height=96 width=96 border=2> <img src="http://www./images/IndexIron04.gif" height=96 width=96 border=2></span></p> </td> </tr> </table> </center> </body>
</html>
|
|