Wednesday, 12 March 2014

Disable right click in blogger

Protect your blogs:

This tweaks helps bloggers to disable right click on the blog.
make your content copyrighted in the sense that it disables right click .
This can save you contend and hard work from directly being copied.
This is an awesome tool, just add few codes
in HTML widget and enjoy!

here is the code:



<script language=javascript>
<!--

//Disable right mouse click Script
var message="copyrighted";

///////////////////////////////////
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> 

you can also change the messageyou want to displayed when right click is pressed 
on your blog. just make a change where copyrighted is written to your own message 
to be displayed:

//Disable right mouse click Script
var message="copyrighted"; 


0 comments:

Post a Comment