Just a moment ago, I visited a website that contains some pictures in its page and some features that I found interesting. Then I was curious about the way it worked, so I tried to right-click on that page in attempt to see the page source. The problem was that the context menu didn’t appear. In brief of second, I successfully accessed the page source, by using Ctrl + U (in fact, almost all browsers can use this key shortcut to access the page source).
So, what is the point of the story above? It’s simple: preventing right clicking on browser is useless, on most case. Underline that.
Well, as I said it’s not totally useless, depends on the purpose of preventing right clicking. In my case, they try to hide the access to page source, and maybe also some other function that can be accessed by using the context menu, such as view the image file, copy the text, view the page info, save the page, etc. However it also disable some useful functions that may cause annoyance for some people, such as accessing bookmark, accessing previous page, reloading the page, etc.
Many people don’t really understand that internet is an open world that can be accessed by everyone (as long as they have privilege to access it, of course). Publishing any material on internet means you have to know the risk that your material can be taken by everyone. There is no absolute way to stop this practice. The only way that can be used to minimize that “bad” practice is by licensing the content or material itself. By giving it license, you may grant people to use it under some terms and conditions, or maybe just prevent them to use it without your permission, but it doesn’t prevent them to take it. If you really serious about your content, you may also give warning to people who use your material without your permission when you find that your content is being used by other people, perhaps by requesting that people to give credit to you, or request them to take down the content. In some rare and extreme cases, you may also sue the “snatcher” if they really take economic advantages by using or selling your content.
So, when do the right-click preventing become useful? The answer is when you need to override the usage of right click itself. As I said, the main usage of right clicking is to open the context menu of your browser. However, when developing some web applications you may need to change the function of right click from opening default context menu to something else like opening custom context menu that you create, creating reverse effect of left clicking, etc. Other than to override it, just leave the right click function as is.
The point here is don’t make the users of your website confuse and have to guess why the right clicking on the page doesn’t work. If you really care about user experience, just let the users or visitors to explore your site without any restriction on usability. You may change the function of right click as long as there is information about the change, but never ever disable right clicking at all.
If you really that afraid that your pictures may be claimed by other people, I suggest you to leave watermarks on all your pictures. A big and repeating watermark so that it will be looked more like pictures of watermarks rather than the original picture that you intend people to see. Sound or song? Insert subliminal message that may be heard like Satan saying the most awkward thing when played in even low speaker volume. For video? Well, watermark it like crazy and insert subliminal message on the audio. How about texts? The craziest way is to convert the text to image, video or song, then do what I’ve said before. Actually, you can insert hidden messages or texts (by using CSS display none), a lot of them, so that when someone try to copy it, it will end up messed. Well, it’s the most evil things that ever comes to my mind.
Seriously, for all those things, you have to trust that your license and copyright will work. And pray to God (if you believe in It/Him/Her), that someone claimed it may be infected by long everlasting hiccup.