Deutsch
<html> <head> <script type="text/javascript"> function handle(delta) { var s = delta + ": "; if (delta <0) s += "down"; sonst s += "up"; document.getElementById('delta').innerHTML = s; }//von downcodes.com Funktion Rad(Ereignis){ var delta = 0; if (!event) event = window.event; if (event.wheelDelta) { delta = event.wheelDelta/120; if (window.opera) delta = -delta; } else if (event.detail) { delta = -event.detail/3; } if (delta) handle(delta); } /* Initialisierungscode. */ if (window.addEventListener) window.addEventListener('DOMMouseScroll', Wheel, false); window.onmousewheel = document.onmousewheel = Rad; </script> </head> <body> <div id="delta">滚动鼠标中间的滚轮可以看到效果</div> </body> </html>