Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

right click/save image

Options
  • 22-03-2004 2:43pm
    #1
    Closed Accounts Posts: 397 ✭✭


    is there anyway to prevent people from saving an image from a webpage?


Comments

  • Closed Accounts Posts: 2,972 ✭✭✭SheroN


    it can be done using javascript.....saw a script for it before...google it.


  • Registered Users Posts: 1,031 ✭✭✭buddy


    Yes, but that just encourages those people to find a way around it - and it is easily done - view source an all.

    Why so important? I'd make a flash file - use a .swf instead of a .jpeg - no right clicking and save as with - more awkward to get at - still - there is always print screen.


  • Closed Accounts Posts: 1,637 ✭✭✭joePC


    Yeah there is always a way around it,

    just put your name across the image using PS,

    You could always attach a virus to a .jpg that would stop them :D

    Thanks joePC


  • Closed Accounts Posts: 304 ✭✭Zaltais


    Yeah - it can be done using a scripting language (e.g. PHP, Perl, ASP) and setting headers to stop the browser from caching the image (when you 'Save As' the browser doesn't actually save the image, it simply copies it from the cache, if there's nothing in the cache, there's nothing to copy.)

    But that still won't stop a user from simply taking a screenshot of the entire page and just cutting the image out if they really want.


  • Closed Accounts Posts: 9,700 ✭✭✭tricky D


    Ain't come across a watertight way for doing this yet. Another method I came across lately for obfuscating code was to encode much of the code as Hexadecimal. So calling foo.gif would be written as %3C%20%69%6D%67%20%73%72%63%3D%22%66%6F%6F%2E%67%69%66%22%3E

    luverly, but if the image is displayed by whatever method, you will be unprotected from determined hackers, just increases their overhead. None of the methods are foolproof.

    hth
    \r


  • Advertisement
  • Closed Accounts Posts: 9,700 ✭✭✭tricky D


    Ain't come across a watertight way for doing this yet.

    er knew that was a bit dodge, check out http://www.antssoft.com/htmlprotector/index.htm

    it sez this on the tin...
    HTML Protector is a tool that helps you protect the content of your web page by preventing others from viewing your source code. Additionally, it will stop spam robots from extracting email addresses from your pages as well as prevent people from using automated downloader's to download your entire web site to their hard drive. HTML Protector offers two JavaScript based encryption methods to choose from and a variety of other features like right click disable, printing disable, password protect your pages, insert copyright information and more
    ymmv


  • Registered Users Posts: 1,967 ✭✭✭Dun


    Even if they do scramble the source code, every man and his dog knows about the right-click - hold - space method of getting around the javascript preventing the right-click. And if they don't, sure they can always take a screengrab.


  • Registered Users Posts: 928 ✭✭✭jabberwock


    Dynamic Drive have alot of good scripts for that sort of thing.


    just have to say though "Down with that sort of thing"


  • Registered Users Posts: 15,258 ✭✭✭✭Rabies


    At the end of the day it doesn't really matter. People can still use 'print screen'. Disabling right click will only stop a small amount of people from saving images.


  • Registered Users Posts: 1,031 ✭✭✭buddy


    Originally posted by Dun
    Even if they do scramble the source code, every man and his dog knows about the right-click - hold - space method of getting around the javascript preventing the right-click. And if they don't, sure they can always take a screengrab.

    That damn dogs been holding out on me! :)


  • Advertisement
  • Closed Accounts Posts: 2,464 ✭✭✭Kristok


    This is really easy to do just put this code into the body

    [PHP]<body>oncontextmenu="return false"</body>[/PHP]

    And put this in as a meta tag

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

    This will stop anyone from rightclicking and also stop ie from loading the image toolbar.

    Would also be good idea then to scramble the code but as someone can just look into their temp files to get the pic if they really wanted its not really worth going any firther than what I have done.


  • Registered Users Posts: 4,276 ✭✭✭damnyanks


    If you are putting an image up on the internet that you dont want people to download here is a simple tip to make sure they can't get at it.


    Dont put it on the god damn internet

    Don't bother messing up your html or adding this that and the other in the hope that it will not be copied. If someone wants it they will get it... it will be slightly annoying to get at it, thats at the very most.

    My suggestion would to be to do either

    A) Watermark the image.
    B) Set up a members area with pay section. At least you'll get some money for it.


Advertisement