鼠标屏蔽问题,请各位高手大力支持
我想实现一个图片不让别得到,也就是不让别人用另存为,或是下载下来,如何实现呀?
------解决方案-------------------- <img src= ' ' .....oncontextmenu= "window.event.returnValue=false ">
------解决方案--------------------屏蔽鼠标右键,用脚本来控制
<script language= "JavaScript ">
<!--
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)
{
event.cancelBubble = true
event.returnValue = false;
return false;
}
}
document.oncontextmenu = nocontextmenu; // for IE5+
document.onmousedown = norightclick; // for all others
//-->
</script>
------解决方案--------------------或者 这样
<script language= "javascript ">
function nomenu()
{
return false;
}
document.oncontextmenu = nomenu;
</script>
或者:
<body oncontextmenu= "javascript:self.event.returnValue=false ">
记得给分呀!!
------解决方案-------------------- <IMG SRC= "mypicture.jpg " HEIGHT= "100px " WIDTH= "100px " GALLERYIMG= "false ">
or
<head>
<meta http-equiv= "imagetoolbar " content= "no ">
</head>
------解决方案--------------------即使 那个图标不可以保存,别人也可以直接IE把你整个网页保存下来 ,那个图片也就跟着下来了