hi, i just wanted to know how can i disable the functions when a user press right click with a mouse? i ask because i will like to avoid people saving my pictures in their computers. can i do that in php or is in java? i will apreciate some code , thanks
Announcement
Collapse
No announcement yet.
question about right click functions
Collapse
X
-
This cannot be done using PHP or Java. You would need to use Javascript. I will move this to the Javascript forum.
Be warned though that other members will point out to you that this is pretty pointless and I am sure they will elaborate on that so I will not.
Moving thread...Spookster
CodingForum Supreme Overlord
All Hail Spookster
-
-
As has been pointed out a zillion times, you cannot protect your code or images from the kind of people who frequent this forum. But the protection may well be effective against the 99% of web surfers who would not recognise a Javascript function if it jumped out of the screen and bit them.
Just as with your physical goods, if someone is a professional thief and is really, really determined to steal them then they will, pretty well regardless of your defences. But simple/ordinary precautions such as no-right-click scripts and a bit of obfuscation will drive away the casual or opportunistic thief.
A paradox is that those who have the expertise and are most able to steal your code and images are those least likely to want to do so - they can write their own, and better!
A no-right-click script also gives very clear notice that the owner of the image does not want it to be copied, and hence whoever takes it knows perfectly well that he is a thief. He cannot say "Oh, I expect the guy will not mind ......", or "If it's on the web it's free for anyone to take, innit?"Last edited by Philip M; Feb 17, 2004, 03:21 AM.
All the code given in this post has been tested and is intended to address the question asked.
Unless stated otherwise it is not just a demonstration.
Comment
-
A paradox is that those who have the expertise and are most able to steal your code and images are those least likely to want to do so - they can write their own, and better!
Comment
-
Glenn - it is not precious. It is probably very poor by your standards. That still does not give people the right to steal it.
In fact stealing from the poor may be worse than stealing from the (knowledgeably) rich such as you!
All the code given in this post has been tested and is intended to address the question asked.
Unless stated otherwise it is not just a demonstration.
Comment
-
I said "precious" from the point of view of those authors that "protect" their html source codes. Of course, I didn't mean "precious" in the real sense of the word, I just used that word to ridicule them.
Comment
-
More to the point - how dare anyone disabled my context menu? What if I want to open a link in a new window, or send some highlighted text to Google?
When I come across a site that uses no-right click (thankfully rare) I make a conscious note never to visit that site again. Presumptuous MF ... deigning to mess around with my user interface.
It's just not on - even if it did stop people looking at source code, the costs involved outweigh the interests being protected. So leave it alone."Why bother with accessibility? ... Because deep down you know that the web is attractive to people who aren't exactly like you." - Joe Clark
Comment
-
ehh ok i got the point, i asked because here in puerto rico , things are getting worse everyday, lots of crimes drugs etc. and in the cyber world many m.......f........ just copy pics from a descent person and publish them just to f..... and i hate that, there many lammers in my island and i just dont wanted to see my pics in others pages with something written that is not true or whatever......but thanks anyway
Comment
-
Originally posted by brothercake
When I come across a site that uses no-right click (thankfully rare) I make a conscious note never to visit that site again. .
All the code given in this post has been tested and is intended to address the question asked.
Unless stated otherwise it is not just a demonstration.
Comment
Comment