Protect Your Web Page Content

Submitted by:Jhon Brain

Date added:17 May, 2012

Category:JavaScript

JavaScript Code example to protect Your Web Page Content

Tags: protect content

Code Snippet:

<SCRIPT language="JavaScript">
<!--
var message="Copyright Year by Your Site. WARNING ! All content contained within this site is protected by copyright laws. Unauthorized use of our material is strictly prohibited.";
function click(e) {
if (document.all) {
if (event.button==2||event.button==3) {
alert(message);
return false;
}
}
if (document.layers) {
if (e.which == 3) {
alert(message);
return false;
}
}
}
if (document.layers) {
document.captureEvents(Event.MOUSEDOWN);
}
document.onmousedown=click;
</SCRIPT>
 
 

Comments