onmouseover="setTimeout('showMsg(event.x,event.y)',3000)" 这句应该怎么写 没人这样写的..onmouseover = showMsg(e)在 showMsg 函数再获取鼠标位置 再setTimeout传入到另外一个函数吧 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 function outtimshowMsg(){showMsg(event.x,event.y);}onmouseover="setTimeout('outtimshowMsg()',3000)"这样也不行,这样的话取不到event.x和event.y的值,有错误帮我写个能用的吧。。谢谢啊 onmouseover="setTimeout(function(){outtimshowMsg(x,y)},3000)" 哎,还是不行,取不到 event.x和event.y的值 定义一个初始化方法init,onmouseover时调用它来确定位置延迟3秒后显示init设置的X和Y<html><head><script>var x=0;var y=0;function init(){ x=event.x; y=event.y;}function showMsg2(){ setTimeout("showMsg();",1000);}function showMsg(){ alert(x+","+y);}</script></head><body> <div style="width:100px;height:100px;background-color:blue;" onMouseOver="init();showMsg2();"></div></body></html> hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh 动态添加的blur事件失效 js报错 permission denied 真是很头疼,达人请进。。。。。 请问当鼠标移动到曲线时,怎样知道鼠标在曲线上面? 怎样取得曲线的坐标? 问个窗口控制的问题! jsp 里面的form处理 一个简单的问题 ~~~在线等待 初学JAVA.真心请教两个问题一.如何在另一框架中自动打开一个网页?二.如果让一个框架最大化 如何在页面中判断用户是否通过点BACK按钮跑到这个页面中的?(100分求答案) 一个简单的问题.帮助者有分.谢谢. 求 漂浮广告代码,支持 IE 、 火狐 叹讨<script src='abc.js'></script>的两种输出方式
showMsg(event.x,event.y);
}
onmouseover="setTimeout('outtimshowMsg()',3000)"这样也不行,这样的话取不到event.x和event.y的值,有错误帮我写个能用的吧。。谢谢啊
延迟3秒后显示init设置的X和Y<html>
<head>
<script>
var x=0;
var y=0;
function init(){
x=event.x;
y=event.y;
}
function showMsg2(){
setTimeout("showMsg();",1000);
}
function showMsg(){
alert(x+","+y);
}
</script>
</head>
<body>
<div style="width:100px;height:100px;background-color:blue;" onMouseOver="init();showMsg2();"></div>
</body>
</html>