HTML Code For prevent copying your content.

Discussion in 'HTML & Website Design' started by Thanan, Nov 21, 2011.

  1. #1
    Put this code on your blog or your site.

    And Put some words on "Put your message here"

    <script language=javascript>
    <!-- http://www.spacegun.co.uk -->
    var message = "Put your message here";
    function rtclickcheck(keyp){ if (navigator.appName == "Netscape" && keyp.which == 3){ alert(message); return false; }
    if (navigator.appVersion.indexOf("MSIE") != -1 && event.button == 2) { alert(message); return false; } }
    document.onmousedown = rtclickcheck;
    </script>
     
    Thanan, Nov 21, 2011 IP
  2. NetStar

    NetStar Notable Member

    Messages:
    2,471
    Likes Received:
    541
    Best Answers:
    21
    Trophy Points:
    245
    #2
    90% of Web Masters who use such a code to protect their HTML Source or Images have nothing worth taking. The best form of protection is a legit copyright and not caring...
     
    NetStar, Nov 21, 2011 IP
  3. cell4review

    cell4review Greenhorn

    Messages:
    88
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    18
    #3
    good post.........keep it up
     
    cell4review, Nov 21, 2011 IP
  4. Cpi2011

    Cpi2011 Peon

    Messages:
    124
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Very useful post thanks for posting !!
     
    Cpi2011, Nov 23, 2011 IP
  5. Qarizma

    Qarizma Member

    Messages:
    55
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    45
    #5
    This is totally not preventing. You can still see the code by viewing the source in your browser.
     
    Qarizma, Nov 23, 2011 IP
  6. mmerlinn

    mmerlinn Prominent Member

    Messages:
    3,197
    Likes Received:
    819
    Best Answers:
    7
    Trophy Points:
    320
    #6
    By definition, your site MUST be downloaded to the users computer BEFORE it can be viewed in his browser. Once it is on his computer, YOU CANNOT PREVENT HIM FROM COPYING IT. All you can do is slow him down.

    If you are so paranoid that you do not want your stuff copied, DO NOT PUT IT ON YOUR WEBSITE.
     
    mmerlinn, Nov 23, 2011 IP
  7. NetStar

    NetStar Notable Member

    Messages:
    2,471
    Likes Received:
    541
    Best Answers:
    21
    Trophy Points:
    245
    #7
    Agreed.

    And the people it slows down are the people who aren't swift enough to know how to use it anyway.
     
    NetStar, Nov 24, 2011 IP
  8. jack2230

    jack2230 Active Member

    Messages:
    209
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    85
    #8
    Agree with you as well. This code won't do to much and your better off just copyrighting the content on your page and if someone takes it go through all the legal stuff as this code won't do much to protect the source code.
     
    jack2230, Nov 24, 2011 IP
  9. Scoty

    Scoty Active Member

    Messages:
    620
    Likes Received:
    8
    Best Answers:
    0
    Trophy Points:
    60
    #9
    A lot of people (more than you might think) surf with JS disabled, so this code would have no affect whatsoever anyway
     
    Scoty, Nov 24, 2011 IP
  10. burminsky_pv

    burminsky_pv Peon

    Messages:
    78
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #10
    If somebody would really want to copy your content then js wouldn't help.
     
    burminsky_pv, Nov 24, 2011 IP
  11. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,999
    Best Answers:
    253
    Trophy Points:
    515
    #11
    Oy gevalt, this cockamamie nonsense again. No, you can't protect it... as mentioned JS off, this script is nothing more than pointless bloated idiocy... It does bupkis in the way of protection -- much less the code for it being a decade out of date... being invalid strict, using the outdated language attribute, checking by browser instead of by capabilities, and putting values into the global namespace; Welcome to 1997... IF one wanted to implement that, it should look something more like this for 2011:

    
    <script type="text/javascript">
    document.onmousedown=function(e) {
    	if (!e) var e=window.event;
    	if (
    		((e.which) && (e.which==3)) ||
    		((e.button) && (e.button==2))
    	) {
    		if (e.preventDefault) e.preventDefault();
    		e.returnValue=false;
    		alert('Your messaage here');
    		return false;
    	}
    	return true;
    }
    </script>
    Code (markup):
    Though again, intercepting right clicks that way is pointless since it's ridiculously simple to bypass -- turn javascript off, save as MHT, document->size in the web developer toolbar... firebug/dragonfly inspection of elements... Or browsers like Opera that allow you to prevent scripts from intercepting right mouse clicks...

    Anyone who tells you this type of script offers any real protection is blowing so much sand up yer tuches you could change your name to Sahara.
     
    deathshadow, Nov 25, 2011 IP
  12. Newviewit

    Newviewit Active Member

    Messages:
    303
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    60
    #12
    no code will ever stop a coder from scraping your site.
     
    Newviewit, Nov 25, 2011 IP
  13. NetStar

    NetStar Notable Member

    Messages:
    2,471
    Likes Received:
    541
    Best Answers:
    21
    Trophy Points:
    245
    #13
    I'm willing to bet over 98% of your real visitors (bots excluded) all have JavaScript ENABLED. I can't think of a single popular website that doesn't provide use of the scripting language.
     
    NetStar, Nov 27, 2011 IP
  14. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,999
    Best Answers:
    253
    Trophy Points:
    515
    #14
    Tell that to the million and a half people who downloaded the noscript plugin for Firefox... tell it to every single Opera user who uses the in-build per-site blocker.

    I actually was arguing that with a guy the other day who said 100% of his visitors had scripting enabled... I pointed out he was relying on a analytic package that only works when scripting is on... That was good for a laugh.
     
    deathshadow, Nov 29, 2011 IP
  15. smartyjohn

    smartyjohn Peon

    Messages:
    115
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #15
    Disabling right Click on your site help your visitors to get annoyed and will not put you in trusted vendor list. So no need to stop copying your content just go for Copyrighting. Coz who need your content can grab it through source code.
     
    smartyjohn, Nov 29, 2011 IP
  16. Rukbat

    Rukbat Well-Known Member

    Messages:
    2,908
    Likes Received:
    37
    Best Answers:
    51
    Trophy Points:
    125
    #16
    What deathshadow said - and I'm still laughing. 100% of people who visited the site with JS enabled had JS enabled?

    Reminds me of a sign on I-95. Something to the effect of "Joes Burgers - the best burger joint in Smalltown" (real names changed to protect the brain-dead). And how many burger joints are there in Smalltown? One.
     
    Rukbat, Dec 1, 2011 IP