Last modified on 18 March 2015, at 12:07

JavaScript/Working with the Mouse

Previous: W3C Event Handlers Index Next: Forms

JavaScript Console TestsEdit

Test x,y

window.onmouseover = function(){document.title = [event.x,event.y];};

Test offsetX,offsetY

window.onmouseover = function(){document.title = [event.offsetX,event.offsetY];};

Test clientX,clientY

window.onmouseover = function(){document.title = [event.clientX,event.clientY];};

Test pageX,pageY

window.onmouseover = function(){document.title = [event.pageX,event.pageY];};

ReferencesEdit

Further readingEdit


Previous: W3C Event Handlers Index Next: Forms