获取鼠标位置
<html>
<head>
<scriptsrc="http://code.jquery.com/jquery-latest.js"></script>
<scripttype="text/javascript">
$(document).ready(function(){
$(document).mousemove(function(){
$("span").text("X:"+event.pageX+",Y:"+event.pageY);
});
});
</script>
</head>
<body>
<p>鼠标指针位于:<span></span></p>
</body>
</html>
相关推荐
gaochujia 2020-06-22
qsdnet我想学编程 2019-11-04
teresalxm 2017-07-14
84296033 2015-07-20
fraternityjava 2015-06-17
jltd00 2015-01-27
muyangzhe 2018-06-18
愚盦 2018-05-21
切慕溪水 2017-07-14
DreamLee 2015-04-22
icecoffeemzp 2011-09-18
FloatDreamed 2011-08-17
maoye 2011-06-19
测试极客 2016-09-13