Two Laptop Bag
The moose likes HTML, CSS and JavaScript and the fly likes Popup Window Position Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Popup Window Position" Watch "Popup Window Position" New topic

Popup Window Position

Steve Dyke
Ranch Hand

Joined: Nov 16, 2004
Posts: 1543
I would like to have a window open at the cursor position. The following will work but does not place the window on the point I click. Also this will not work if the function is called from a hyperlink tag(javascript:"cursortest()")

Eric Pascarello

Joined: Nov 08, 2001
Posts: 15385
Why are you using moveTo? There is top/left

Also your code is not cross browser friendly. window.event is IE only.

I agree. Here's the link:
subject: Popup Window Position
jQuery in Action, 3rd edition