[jQuery] Re: How to catch mouse position inside an area?

2009-04-22 Thread Daniel
something like... $(#div).click(function() { var ox = $(this).offset().left; var oy = $(this).offset().top; } On Apr 22, 6:36 am, David .Wu chan1...@gmail.com wrote: If I got a 400px width div, can I get the offset left distance from mouse to the div in where I click?

[jQuery] Re: How to catch mouse position inside an area?

2009-04-22 Thread Richard D. Worth
See http://docs.jquery.com/Tutorials:Mouse_Position#Where_did_they_click_that_div.3F - Richard On Wed, Apr 22, 2009 at 7:36 AM, David .Wu chan1...@gmail.com wrote: If I got a 400px width div, can I get the offset left distance from mouse to the div in where I click?