home *** CD-ROM | disk | FTP | other *** search
- <HTML>
-
- <HEAD>
-
- <TITLE>Mouse Movements</TITLE>
-
- </HEAD>
-
- <SCRIPT language="javascript">
-
- document.captureEvents(Event.MOUSEMOVE);
-
- function HandleEvent (e) {
-
- message = "Event = " + e.type + ". "; //identify the event type
-
- message += "x,y position = " + e.layerX + ", " + e.layerY; //where click was
-
- document.displayForm.coordinates.value = message; //display the information
-
- return true;
-
- }
-
- document.onmousemove = HandleEvent;
-
- </SCRIPT>
-
- <BODY>
-
- <H1>Here's a page</H1>
-
- <P>Howdy</P>
-
- <H1>Here's a page</H1>
-
- <P>Howdy</P>
-
- <H1>Here's a page</H1>
-
- <P>Howdy</P>
-
- <FORM name="displayForm">
-
- <INPUT name="coordinates" type=text size="45">
-
- </FORM>
-
- </BODY>
-
- </HTML>
-
-