Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Jun 2002
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Mouse Coordinates

    I have looked all over, and found plenty of scripts that tell you the mouse coordinates while your cursor is in the window. But what I really want, is a script that tells me the mouse coordinates whether the cursor is in the window or not. Any one know if this is possible?

  • #2
    Senior Coder A1ien51's Avatar
    Join Date
    Jun 2002
    Location
    Between DC and Baltimore In a Cave
    Posts
    2,717
    Thanks
    1
    Thanked 94 Times in 88 Posts
    you can just do something like this....It will set a variable which you could check for in whatever you are doing

    <html>
    <head>
    <script>
    function MouseLoc(X){
    MouseLocated=X;
    //1==In the Window
    //2==Out of Window
    }
    </script>
    </head>
    <body onmouseover="MouseLoc(1)" onmouseout="MouseLoc(0)">
    </body>
    </html>

  • #3
    New to the CF scene
    Join Date
    Jun 2002
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks A1ien51, that did the trick.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •