对页面文字进行保护的脚本,使用后页面上的文字就不能被鼠标选择了,感觉好像成了图片似的,对一些想保护自己文学作品的页面也许有用吧,可是......识破的方法依然很多!
制作方法:
在<head>标签下,粘贴代码:
<script language="JavaScript1.2">
function disableselect(e){
return false}
function reEnable(){return true
}
//if IE4+
document.onselectstart=new Function ("return false")
//if NS6
if (window.sidebar){
document.onmousedown=disableselect
document.onclick=reEnable
}
</script>
至此,我们的效果便制作好了,你不仿试试!
本文作者: