• Howdy! Welcome to our community of more than 130.000 members devoted to web hosting. This is a great place to get special offers from web hosts and post your own requests or ads. To start posting sign up here. Cheers! /Peo, FreeWebSpace.net
managed wordpress hosting

Disable Right Click or change Right Click options

ckevin

New Member
I have searched some JavaScripts for Disable Right Click on all browser area or just on image area. However, I need some JavaScripts that can disable people to right click in all broswer area but NOT IMG tags, so that people can right click and save or print that image with other IE statndard right click options.

If it can't be achieved, is it possible to customize the right click option, so that people can only save, print the image?

Thank you!
 
i think the first thing you asked for might be kind of hard or impossible... the second shouldn´t be too hard to do with a custom right click menu...

scripts like that usually have some browser compatability issues though...
 
i hate it when people disable right clicking because i like to open links up it in to windows


also if your doing this to stop people from viewing your source code, it wont work.
 
hehe :)

You can't stop someone who wants something badly - trust me on this one..

Its funny, people put bars on their windows (houses), and still get robbed.
 
You do know that people can still see your source and all by going to View>Source, right? ;)
 
Originally posted by Daniel
You do know that people can still see your source and all by going to View>Source, right? ;)
Still ways of disabling that.
Though there was some mad code in the last issue of 2600, spring 2002 I think it was. Crazy code about right click supression. :rolleyes:
 
Normally, I won't use those "Disable Right Click" feature in my personal site, I also think it's annoying. However, I'm working a small scripts that need this feature - can save / print wallpaper but can't view my source (prevent hot linking etc. | Visitors cannot View>Source because I restrict them to open a new browser without Menu Bar, otherwise, they can't enter to the page), Since my script is written in PHP, I don't know how to encode the frontend HTML. Any idea?

Thanks for your idea and links! :)
 
Don't bother with Javascript. If someone wants your code, then can get at it. If you are worried about hotlinking, .htaccess can stop that.
 
Back
Top