Http://home.51.com/lontenda/diary/item/10011460.html
Prohibit save page
1. Prohibit Save As
<nos cript><iframe Src=-.html></iframe></nos cript>
Join the head.
2. Prohibit right-click
<body oncontextmenu= "return false" >
Or
<s cript language= "Javas cript" >
<!--
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
-
</S cript>
3. Let the page text not be selected and copied
<body onselectstart= "return false" >
Or
<body Oncopy=alert (' Sorry, no copying. ');event.returnvalue=false;>
4. Lock status bar text to prevent the address from appearing
<body onmouseover= "self.status= ' text '; return true" >
7. Prohibit image download
At the end of <body......> here add:
Oncontextmenu= "return false" ondragstart= "return false" onselectstart= "return false" scroll= "Auto"
5. Disable caching
<meta http-equiv= "Expires" content= "0" >
<meta http-equiv= "Cache-control" content= "No-cache" >
<meta http-equiv= "Pragma" content= "No-cache" >
Put it in the head.
6. Use the Include Page
Encrypt the included page address, using the tool htmlguardian5.3.5
Currently the most powerful HTML code encryption software, can protect the connection and the HTML code is stolen. 1. Right-click the lock. 2. Disable Mouse circle. 3. Offline use is not allowed. 4. Password protection. 5. The Status bar URL address is not displayed. 6. Full code or local code protection. 7. Link Tracking. 8. Prohibit printing (ie5+). 9. Compress the code (before it is unencrypted). 10. *.html *.js *.asp *.vbs can be encrypted. 11. Two different encryption algorithms. 12. Encrypt the frameset structure. 13. Some features support several different versions of the browser.