jimzstone Moderator
Posts : 67 Points : 5605 Reputation : 2 Join date : 2009-02-19 Age : 32 Location : Laguna
Planet Shake huo: 4
| Subject: Right Click Block Fri Feb 20, 2009 12:23 am | |
| in some sites the right click block is not working.so use this code and place it in text at top of the page.or if you want to block only certain pages then place in the source code of page - Code:
-
<!-- Right click block code from www.tharunzworld.co.cc starts here --> <script language=Javascript> <!-- var message="Function Disabled!";
/////////////////////////////////// function clickIE4(){ if (event.button==2){ alert(message); return false; } }
function clickNS4(e){ if (document.layers||document.getElementById&&!document.all){ if (e.which==2||e.which==3){ alert(message); return false; } } }
if (document.layers){ document.captureEvents(Event.MOUSEDOWN); document.onmousedown=clickNS4; } else if (document.all&&!document.getElementById){ document.onmousedown=clickIE4; }
document.oncontextmenu=new Function("alert(message);return false")
// --> </script> <!-- Right click block code from www.tharunzworld.co.cc ends here --> Enjoy | |
|