No Right Click Function

Discussion in 'HTML & Website Design' started by newdude, Feb 26, 2008.

  1. #1
    i want to put code into my new site to stop people from right clicking and being able to save pictures. i have the code. it's called "No right click" or "disable right click". tons of people posted it on the internet.

    but the code is supposed to get place in the <HEAD> section. one site warns that any JavaScript code placed at the top of a web page could easily confuse a search engine spider.

    i dont want to risk getting a cr@ppy search engine rank though. should i be concerned?

    and yes, i know that people can still take a screen shot if they are that determined to have the picture. but i'd like to avoid right click saves because my average visitor probably doesnt know about the screen shot function.

    thanks!
     
    newdude, Feb 26, 2008 IP
  2. dboldt

    dboldt Peon

    Messages:
    4
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    they can also do a view/view source from the pull down menu up top and get all the images directly from the source. You could add some code to only allow images to be loaded when your page is the referrer, but it will not work in every browser out there. Furthermore, the images are all stored in the temporary internet files directory on the local machine, so they could simply get them from there after loading your site once.

    Don't waste your time with 'right click' prevention. There are too many ways around it.
     
    dboldt, Feb 26, 2008 IP
    the Patrician likes this.
  3. jestep

    jestep Prominent Member

    Messages:
    3,659
    Likes Received:
    215
    Best Answers:
    19
    Trophy Points:
    330
    #3
    I wouldn't be concerned with any loss of ranking, but disabling right clicks or any other normal browser behavior is a huge usability no-no. It's really annoying when websites do that, and if someone wants a picture, they will get it even if they are not tech-savvy.

    You may want to digitally or visibly watermark your images. I definitely recommend against disabling right clicks.

    As far as actually doing it, put the javascript in an external file and call it at the foot of your site. You want it to be the last thing to load so that it doesn't slow down the rest of the website from loading.
     
    jestep, Feb 26, 2008 IP
  4. innovati

    innovati Peon

    Messages:
    948
    Likes Received:
    63
    Best Answers:
    1
    Trophy Points:
    0
    #4
    Firefox > Preferences > Content > Enable Javascript >> uncheck.

    Now your little script doesn't even load. Too bad for you.

    Alternatively, you do realize that people don't view your images from your site, they view the images they downloaded from your site from the temp folder in their web cache on their own hard drive. By the time they see the image to bother right clicking on it, it's already in their hard drive.

    They can:

    - Manually go into the cache, mine's ~/.firefox/users/cache and move the file to anywhere else on their hard drive that they want

    - Firefox > Tools > Page Info > Media > list of all of the files in the cache that were loaded by the page they're currently viewing, select one and it has a giant button that says: Save As...

    I've said it before on these forums and I will say it again: IF YOU DONT WANT PEOPLE TO HAVE YOUR CONTENT DONT PUT IT ON THE INTERNET

    It's safe on your hard-drive, just save yourself the trauma if it's that precious to you.

    If it's a sample of work that you don't want people stealing, you could take alternative measures like watermarking, putting coloured (usually red) 1pixel lines through the work a couple of times. Maybe you could put a low quality version online, either small or compressed as a JPG.

    Honestly though, if you put some sort of sassy no-no dialog box when I right click on your site, I won't ever return again. Part of my natural navigation and web browsing is going to a page, right-clicking on any links that tickle my fancy and open them in new tabs. If you disable my right click (and in the process my ability to view potentially more of your site) and 'punish me' with some sassy quote about not stealing your stuff (usually people that do this have stuff I wouldn't bother looking at twice anyway) I will honestly not return and just leave right then and there.

    So yes, there are tons of scripts, but I think even if searchbots are slightly affected by it, I know it causes massive navigation problems and a really bad first impression to all *human* visitors.
     
    innovati, Feb 26, 2008 IP
  5. kreativi

    kreativi Peon

    Messages:
    89
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #5
    You can find several scripts for disabling right click. But there are several alternates as mentioned above. Always keep in mind you can not save any of your online material from being copied. So don't waste your time in these type of things.
     
    kreativi, Feb 26, 2008 IP
  6. Wuiqed

    Wuiqed Well-Known Member

    Messages:
    110
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    108
    #6
    Keep in mind that that such an extreme measure just to keep your content less-than-slightly safe will effectively break a lot of the visitor's experience. You take away their ability to go back, to go forward, to refresh, to add a bookmark, to print and any other important functionality they use via the right-click menu. Sure, there's always the toolbar, but you should never force such a behaviour on a visitor; they might find it annoying and leave. I know I would.

    No, go for a safe technique, e.g. watermarking. It can be done on the fly via a script and is relatively simple and safe. Security by obscurity is never a good option.
     
    Wuiqed, Feb 27, 2008 IP
  7. AstarothSolutions

    AstarothSolutions Peon

    Messages:
    2,680
    Likes Received:
    77
    Best Answers:
    0
    Trophy Points:
    0
    #7
    If you dont want them copied, dont put them on the net. If you put them on the net they can easily be copied.

    Watermarking is one option depending on if you are talking about images in the body of the site or if you are talking about images that make up the design. If you do it on the fly then you want to do it at the point of upload, it would be terribly inefficient to watermark an image each time that it is requested.
     
    AstarothSolutions, Feb 27, 2008 IP
  8. newdude

    newdude Guest

    Messages:
    7
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #8
    um...can someone please answer my question, which has to do with search engine optimization, without a rant about content and useability???

    thank you.
     
    newdude, Feb 27, 2008 IP
  9. camp185

    camp185 Well-Known Member

    Messages:
    1,653
    Likes Received:
    51
    Best Answers:
    0
    Trophy Points:
    180
    #9
    newdude, you should know that when someone visits a website all the images automatically go into that persons computers cache. They have your pictures without even trying. If you are that concerned, and are selling the images or something have a flash expert build you a site. Much more difficult to get pictures for a flash file. Of course there is still the prt sc option or splash application that will still defy your efforts. Best advice to you is use astarothsolutions advice.
     
    camp185, Feb 27, 2008 IP
  10. gummybear

    gummybear Member

    Messages:
    53
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    43
    #10
    Why not just put the code in a *.js file and include it in the head?

    But others have commented on why no right click sucks because as internet surfers, we hate it too. Making visitors dislike your website is not the best way to do business.
     
    gummybear, Feb 27, 2008 IP
  11. newdude

    newdude Guest

    Messages:
    7
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #11
    again, can someone PLEASE PLEASE PLEASE (with a cherry on top) answer my question, which has to do with search engine optimization, without a rant about content and useability??? shprekenzie english? sorry to be sounding like a j/rk but this is very frustrating that no one will give a straight answer.

    thank you.
     
    newdude, Feb 27, 2008 IP
  12. nicangeli

    nicangeli Peon

    Messages:
    828
    Likes Received:
    23
    Best Answers:
    0
    Trophy Points:
    0
    #12

    I agree with every single "rant" above, and as far as search engines go, putting a script in your document shouldn't affect how search engines crawl your site.
     
    nicangeli, Feb 27, 2008 IP
  13. juan-roman

    juan-roman Peon

    Messages:
    26
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #13
    I have done a good bit of SEO and dabbled in forums and I've never heard the Javascript in the HEAD being a no-no.

    A forum that might help to answer your question in more detail is forums.seochat.com.


    JR
     
    juan-roman, Feb 27, 2008 IP
  14. kreativi

    kreativi Peon

    Messages:
    89
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #14
    JavaScript at the head section of webpage will make it little complex for Spiders to Crawl your webpage. It is better to avoid it unless you need it very badly.

    Even the images from GettyImages and Corbis are being copied. Then how can you expect that you can save your images from being copied.

    You can have one possible option, put your images on background and place a transparent .gif at the top of it.
     
    kreativi, Feb 27, 2008 IP
  15. chris265

    chris265 Peon

    Messages:
    702
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    0
    #15
    Anyone who wants to can get around this. It is not worth your time and people hate sites with it
     
    chris265, Feb 27, 2008 IP
  16. kk5st

    kk5st Prominent Member

    Messages:
    3,497
    Likes Received:
    376
    Best Answers:
    29
    Trophy Points:
    335
    #16
    Most folks probably ignored the minor issue of search engines and javascript because the consensus is don't use the javascript in the first place.

    But, if you want to know for general information, it has no negative effect to have a link to your javascript in the head. That's where it generally belongs. One should not have the javascript itself anywhere on the page.

    Good seo is about having a high signal to noise ratio.

    cheers,

    gary
     
    kk5st, Feb 27, 2008 IP
  17. vishnups

    vishnups Banned

    Messages:
    166
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    0
    #17
    We can protect the images and saving images by using php. I have done it before..PM me if interested.
     
    vishnups, Feb 27, 2008 IP
  18. Cancunvibe

    Cancunvibe Peon

    Messages:
    18
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #18
    Make a table and use the picture as a background that seem to work fine
     
    Cancunvibe, Feb 27, 2008 IP
  19. mutley

    mutley Peon

    Messages:
    356
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #19
    yes it would be best to put all your imeges in to flash but if you want an easy way to stop most people from right clicking

    try this code

    oncontextmenu="return false;"

    put it in your opening body tag like this

    <body oncontextmenu="return false;"</body>

    hope this some help to you ?
    ps it works in both firefox and IE
     
    mutley, Feb 28, 2008 IP
  20. Stomme poes

    Stomme poes Peon

    Messages:
    3,195
    Likes Received:
    136
    Best Answers:
    0
    Trophy Points:
    0
    #20
    ^ so I click View Source in my browser, find the paths to the images and save. Ta da : )
     
    Stomme poes, Feb 28, 2008 IP