Quantcast

Disabling the Right-click Mouse Button

Get the WebProNews Newsletter:
[ Business]

Sometimes you don’t want the visitor to be able to click the right mouse button and do all the stuff associated with it. Although personally I’m not in favor of such gimmicks and limit the visitor’s independence, you learn something new in this tutorial.

NOTE: Before testing the script, remove the dot preceding the tag. It has been put there to prevent the script from executing.

-==-

The above code checks what browser the user is using and store the information accordingly. Both the browsers use different class variable names to store different events.

-==-
And the code below captures the event and sends it to the browser.

-==-

Amrit Hallan is a freelance copywriter,
and a website content writer. He also dabbles
with PHP and HTML. For more tips and tricks in
PHP, JavaScripting, XML, CSS designing and
HTML, visit his blog at

http://www.aboutwebdesigning.com

Disabling the Right-click Mouse Button
Comments Off
This entry was posted in Business.
About Amrit Hallan
Amrit Hallan is a freelance copywriter, and a website content writer. He also dabbles with PHP and HTML. For more tips and tricks in PHP, JavaScripting, XML, CSS designing and HTML, visit his blog at http://www.aboutwebdesigning.com WebProNews Writer
Top Rated White Papers and Resources

Comments are closed.