How can I put an image into my webpage and prevent users to save it in their computers? I need to prevent users to use the Print Screen button on their keyboards and take a photo of my flash application... how can I use jQuery or JavaScript (or something like them) to do it?
I am not sure that how you can prevent user from taking screen shot. But there is a way to prevent right click and saving your image. Not using js, but with css. Just set the image as background-image
instead of setting image tag src
.
I have been using this for some time. It works for me. It has some pros and cons.
Pros:
Cons:
background-size
property. See below. But background-size
browser support is not good.) Still the user can save the image if he wants(with some developer tools &&|| etc), but all the users are not aware about that.
You can also use background-size: auto | contain | cover;
background-size: auto | contain | cover;
property.
I hope this may help you!
Unforunately you can't. its a built in function to the operating system.
It's fairly safe to say that you can't. There always the possibility to block the right-click in js, but that's as far as you can go.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.