admin管理员组

文章数量:1375841

Is there a way to prevent users from saving images when they do a save as?

I have already disabled right click in the pages using javascript as well as adding the following header:

<meta http-equiv="imagetoolbar" content="no" /> 

But if I go for example in OPERA and do page -> save as -> html file with images all the images will get saved. IS there a way to counter this?!

Is there a way to prevent users from saving images when they do a save as?

I have already disabled right click in the pages using javascript as well as adding the following header:

<meta http-equiv="imagetoolbar" content="no" /> 

But if I go for example in OPERA and do page -> save as -> html file with images all the images will get saved. IS there a way to counter this?!

Share Improve this question asked Mar 19, 2012 at 11:51 DumboDumbo 14.2k56 gold badges193 silver badges291 bronze badges 3
  • 14 seriously what is this, 1999? – qwertymk Commented Mar 19, 2012 at 11:52
  • 1 Sean wele to the future (: – mauris Commented Mar 19, 2012 at 11:53
  • 1 something should be done with SO reputation system . Seriously ... – themihai Commented Mar 19, 2012 at 11:54
Add a ment  | 

4 Answers 4

Reset to default 7

They will always be saved. Your browser caches images locally anyway, so they'll always be downloaded to a users machine and if they wanted to take them, they would.

The only way to stop images from being saved is don't put them on the internet.

No, there is not. If an HTTP client can download it, it can save it. It is a futile effort to try and counter this.

Edit: Also, I'd like to point out that most browsers allow the user to forcefully (re-)enable the right-click menu on evil websites who try and take that freedom away from them.

No, there is always a way for users to get your images. If you dont want your images reused consider watermarking them if this is appropriate or branding them with the pany logo.

Disabling right click will just annoy the hell out of users who probably wouldnt steal your images anyway, and be a minor inconvenience to those who would.

No right click? Just screenshot the page, maybe view source and go directly to the image file, etc etc.

Just out of curiosity, why do you even want to do this?

You can do what the author of this page did with a picture of Homer Simpson. Look ma, no <img>!

本文标签: javascriptPrevent saving images from website (save whole page)Stack Overflow