window.onmousewheel in Firefox
firefox, javascript, jquery, mousewheel
Solution
Firefox doesn't support `.onmousewheel`, you have to use the `DOMMouseScroll` event instead:
$(document).on( "mousewheel DOMMouseScroll", function(e){
e.preventDefault();
});
Problem
This code disabled mouse scroll functionality, when i click on the document. ``` $(document).on("click", function () { window.onmousewheel = function (e) { e.preventDefault(); } }); ``` but, this working in all browsers except Firefox. tell please, how to make this code as cross-browser ?