代码很混乱,完全可以缩减一半
<body> <div id="test1"> <table> <tr> <td id="m1"> <table> <tr> <td><img src="http://www.jq22.com/img/6.png" /></td> </tr> </table> </td> <td id="m2"></td> </tr> </table> </div> <script> window.onload = function() { m2.innerHTML = m1.innerHTML; var t = setInterval(run, 10); }; function run() { (++test1.scrollLeft >= m1.clientWidth) && (test1.scrollLeft = 0) } </script> </body>回复