onScroll event doesn't trigger using scroll wheel instead of scroll bars
pliny
9:28 pm on Jan 13, 2005 (gmt 0)
This simple bit of code effectively, if not perfectly, prevents users from scrolling when certain browsers insist on displaying scroll bars against my explicit instructions:
<BODY onScroll="window.scroll(0,0);">
This works when I scroll using the scroll bars, _but_ the JS is not catching the event when I use my mouse's scroll wheel instead of the scrolly bars. Any enlightenment here?
tforcram
10:09 pm on Jan 13, 2005 (gmt 0)
Why would you want someone to not be able to scroll, what if they have/or make the window really small. I would think the best solution is just to make all your material fit into the dimensions you want with css.
pliny
11:41 pm on Jan 13, 2005 (gmt 0)
It's a design decision.
I've been reading some more, and it appears that there may be no real eventhandler to catch a scrollwheel scroll. If anyone knows different, please advise--thanks.
Rambo Tribble
11:43 pm on Jan 13, 2005 (gmt 0)
I suspect the problem with the scroll wheel is out of your hands; the driver for the mouse isn't reporting the event to the OS, which in turn isn't reporting it to the browser.