<div class="htmlarea"> <textarea id="runcode99808"> <title>改变图片重叠顺序</title> <style type="text/css"> .s1{position:absolute; top:10;left:10; } .s2{position:absolute; top:50;left:50; } </style> <script language="javascript"> <!-- function ch(obj){ ID1.style.zIndex = 0; ID2.style.zIndex = 0; obj.style.zIndex = 1; } //--> </script> <img src="http://files.jb51.net/upload/201010/20101031232216942.jpg" id="ID1" class="s1" onmouseover="ch(this)" alt="JavaScript 控制图片改变重叠顺序的代码(鼠标移动切换)_图象特效" > <img src="http://files.jb51.net/upload/201010/20101031232216617.jpg" id="ID2" class="s2" onmouseover="ch(this)" alt="JavaScript 控制图片改变重叠顺序的代码(鼠标移动切换)_图象特效" > </textarea><br><input onclick="runEx('runcode99808')" type="button" value="运行代码"> <input onclick="doCopy('runcode99808')" type="button" value="复制代码"> <input onclick="doSave(runcode99808)" type="button" value="保存代码">[Ctrl+A 全选 注:<a href="http://www.jb51.net/article/23421.htm" title="查看具体详情" target="_blank">如需引入外部Js需刷新才能执行</a>]</div>