How to to disable right click using javascript?

I am posting this article as per the one of my user request. It is easy to disable right click in a website using javascript.

Code to disable:
oncontextmenu="alert('right click is disable');return false;"

now you may have doubt about placing this javascript code. This code should be in body as one of the attribute.

I think you can understand better if i give example.

Lorem ipsum is simply dummy text of the printing and typesetting industry.

Comments