How To: No Right Clicking In WordPress

Recently we setup a new website for a client who is a great photographer. The account rep for this client is Yvonne Barber and she had a thought about protecting this client’s images from people who may want to try to use them without proper permission. It was a valid point because as of right now, the client wasn’t looking to sell nor allow for licensed downloads of his images for any type of use.

Well we found a nice piece of jQuery code that we were able to add to his Header.php file that disables the right clicking option in most browsers. See the short video below for a step by step way to do it yourself, even if you’re not a seasoned programmer.

Here is the code:

<script type=”text/javascript”>
$(document).ready(function(){
$(document).bind(“contextmenu”,function(e){
return false;
});
});
</script>

3 replies

Comments are closed.