标题:
[分享]
鼠标左右键测试
[打印本页]
作者:
NWWOLFGANG
时间:
2007-11-16 21:38
标题:
鼠标左右键测试
鼠标左右键测试<html>
<head>
<title>鼠标左右键测试</title>
<!--HarryPotter-->
<scrīpt language="javascrīpt">
function Mytest()
{
if (event.button == 1)
alert("你好");
else
{
alert("禁止右键!");
setTimeout("CloseWiondows();",30000)
}
}
function CloseWiondows()
{
window.close();
}
</scrīpt>
</head>
<body ōnmouseup="Mytest();">
点击鼠标左键弹出"你好"</p>
点击右键弹出禁止右键</p>
30秒后关闭窗口</p>
</body>
</html>
欢迎光临 IT家园 (http://bbs.it998.com/)
Powered by Discuz! 7.2