Télécharger des logiciels Windows, Mac, Linux, Palm, Pocket PC, Mobile, Jeux, scripts PHP, script ASP, scripts CGI, scripts PERL. Télécharger des cours, des wallpapers, des curseurs, des gifs animés, des fonds d'écran, fonds d'écrans, des textures, des icônes, des dessins. Gratuiciels, freeware, shareware, démonstration, gratuit.
Faites le plein de téléchargements !

 
 
 
 
 
 
 
 
 
 Télécharger le script javascript Capturing Mouse - Toocharger.com.
l►► Télécharger Capturing Mouse v1.0. Capturing Mouse affiche la position du curseur de la souris en X et Y à l'écran. Script Capturing Mouse. Téléchargement de Capturing Mouse, download.
Vous êtes ici : Scripts > Javascript > Divers > Capturing Mouse

Scripts PHP, ASP, Flash, CGI-PERL, Javascript, ASP.NET, Python, C, C++, DHTML, XML et CFM

SCRIPT JAVASCRIPT CAPTURING MOUSE v 1.0

 

Script javascript Capturing Mouse
Agrandir Cliquez pour agrandir
Capturing Mouse affiche la position du curseur de la souris en X et Y à l'écran.

  • Une
    Télécharger

CODE SOURCE (imprimer) :
  1. <!--
  2. ============================================================
  3. Capturing The Mouse Position in IE4-6 & NS4-6
  4. (C) 2000 www.CodeLifter.com
  5. Free for all users, but leave in this header
  6. //-->
  7.  
  8. <html>
  9. <body>
  10.  
  11. <!-- Part One:
  12. Set up a form named "Show" with text fields named "MouseX"
  13. and "MouseY". Note in the getMouseXY() function how fields
  14. are addressed, thus: document.FormName.FieldName.value
  15. //-->
  16.  
  17. <form name="Show">
  18. <input type="text" name="MouseX" value="0" size="4"> X<br>
  19. <input type="text" name="MouseY" value="0" size="4"> Y<br>
  20. </form>
  21.  
  22. <!-- Part Two:
  23. Use JavaScript ver 1.2 so older browsers ignore the script.
  24. The &lt;script> must be *after* the &lt;form> -- since the form
  25. and fields must exist *prior* to being called in the script.
  26. //-->
  27.  
  28. <script language="JavaScript1.2">
  29. <!--
  30.  
  31. // Detect if the browser is IE or not.
  32. // If it is not IE, we assume that the browser is NS.
  33. var IE = document.all?true:false
  34.  
  35. // If NS -- that is, !IE -- then set up for mouse capture
  36. if (!IE) document.captureEvents(Event.MOUSEMOVE)
  37.  
  38. // Set-up to use getMouseXY function onMouseMove
  39. document.onmousemove = getMouseXY;
  40.  
  41. // Temporary variables to hold mouse x-y pos.s
  42. var tempX = 0
  43. var tempY = 0
  44.  
  45. // Main function to retrieve mouse x-y pos.s
  46.  
  47. function getMouseXY(e) {
  48. if (IE) { // grab the x-y pos.s if browser is IE
  49. tempX = event.clientX + document.body.scrollLeft
  50. tempY = event.clientY + document.body.scrollTop
  51. } else { // grab the x-y pos.s if browser is NS
  52. tempX = e.pageX
  53. tempY = e.pageY
  54. }
  55. // catch possible negative values in NS4
  56. if (tempX < 0){tempX = 0}
  57. if (tempY < 0){tempY = 0}
  58. // show the position values in the form named Show
  59. // in the text fields named MouseX and MouseY
  60. document.Show.MouseX.value = tempX
  61. document.Show.MouseY.value = tempY
  62. return true
  63. }
  64.  
  65. //-->
  66. </script>
  67. </body>
  68. </html>

 Auteur inconnu
 Site web de l'éditeur
 Date de publication 11/07/2008
 Langue anglais
 Type de licence gratuit
 Licence -
 Bases de données Aucune
 Téléchargements total 520
 Téléchargements ce mois 2

Note des utilisateurs

-/10

Fonctionnalités
Blank
Interface
Blank
Stabilité
Blank
Installation
Blank
Rapport qualité/prix
Blank
Avis général
Blank
Nbre d'avis : 0

Blank




Blank


Il n'y a pas d'avis enregistrés pour le moment, vous pouvez enregistrer le vôtre.

Copyright © 2004-2009 Webluna. Tous droits réservés.
Hebdotop