<!--
if (window.Event)
document.captureEvents(Event.MOUSEUP)
function nocontextmenu()
{
event.cancelBubble = true
event.returnValue = false
return false
}
function norightclick(e)
{
if (window.Event)
{
if (e.which == 2 || e.which == 3)
return false
}
else
{if (event.button == 2 || event.button == 3) {alert("【E路极速】欢迎你")} }
{
event.cancelBubble = true
event.returnValue = false
return false
}
}
document.oncontextmenu = nocontextmenu// for IE5+
document.onmousedown = norightclick// for all others
//-->
</scrīpt>
//以下为禁止鼠标右键的代码,不想禁止的可以删除<!--
if (window.Event)
document.captureEvents(Event.MOUSEUP)
function nocontextmenu()
{
event.cancelBubble = true
event.returnValue = false
return false
}
function norightclick(e)
{
if (window.Event)
{
if (e.which == 2 || e.which == 3)
return false
}
else
{if (event.button == 2 || event.button == 3) {alert("【E路极速】欢迎你")} }
{
event.cancelBubble = true
event.returnValue = false
return false
}
}
document.oncontextmenu = nocontextmenu// for IE5+
document.onmousedown = norightclick// for all others
//-->
</scrīpt>
要是因为这个原因的话那就是你调用函数的时候参数有问题。虽然编译器不提示但是肯定有问题。我在动态调用函数的时候就出现过这种莫名的错误。郁闷了半天。最后才发现是参数类型不匹配。你仔细看看你那个处理鼠标事件的函数。欢迎分享,转载请注明来源:夏雨云
评论列表(0条)