Lively discussions on the graphic arts and publishing — in print or on the web

Go Back   Desktop Publishing Forum > General Discussions > Web Site Building & Maintenance

Thread Tools Display Modes
Old 02-24-2006, 06:07 AM   #1
John Woram
Join Date: Aug 2005
Posts: 28
Default Mouse position problem

I wrote a little script to detect mouse position--a stripped-down version is pasted below, just to show the basic coding. This works fine in IE and Firefox. As the mouse moves within the window, its X/Y coordinates are displayed in the form. HOWEVER (there's always a "however" ), if I add any "<!DOCTYPE ..." statement at the top, then in IE it only works if the mouse stays within the red-outlined form boundary. Is this just another IE bug, or is there something I can add to make IE happy? Or is there some alternative script that will do the same thing?


<script type="text/javascript">
function mouseCoords(event){
<style type="text/css">
form {border:1px solid red;}
<body onmousemove="mouseCoords(event)">
<form name="showXY">
<input name ="xPos" type="text" /><br />
<input name ="yPos" type="text" />
John Woram is offline   Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
DW8 mouse-over errors zofiaphoto Web Design 9 08-18-2006 09:06 AM
Web rank position software ktinkel Web Site Building & Maintenance 0 05-11-2006 07:55 AM
Laptop mouse Richard Waller The Corner Pub 1 05-08-2006 04:29 AM
Squashed mouse! Kelvyn The Corner Pub 1 01-09-2006 12:13 PM
New mouse! iamback General Publishing Topics 5 12-20-2005 02:30 PM

All times are GMT -8. The time now is 06:57 PM.

Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2023, vBulletin Solutions, Inc.
Contents copyright 2004–2019 Desktop Publishing Forum and its members.