PDA

View Full Version : Image swap when saved



Gooseberry
07-08-2014, 11:51 AM
I *think* what I'm looking for is javascript. I used it (~10) years ago, so I know it exists somewhere in the ether.

I wish to prevent people from saving pictures from a website, but I do not want to block right clicking.

I would like it to swap the image someone is trying to save for another one.
(I used to a giant smiley emoticon in the past ;)).

Can someone point me towards the relevant script, or suggest an alternative, please :)

Deadweight
07-08-2014, 10:53 PM
Using JQuery:


$('img').bind('contextmenu', function(e) {
return false;
});


http://jsfiddle.net/wM8Zm/622/

Gooseberry
07-08-2014, 11:28 PM
Using JQuery:


$('img').bind('contextmenu', function(e) {
return false;
});


http://jsfiddle.net/wM8Zm/622/

Ooooo - is it that simple? Wow! Thank you :)