Try the Most Addicted Game - Real Rocket Racing 3d Game

Wednesday, November 23, 2011

Pin It

Widgets

Preventing Copy/Paste Show Your Copyright


The use of this trick is when someone copy/paste your blog articles into their blog it will automatically shows copyright and link source of the post. Lets is how to add this to your blog

For Live Demo open Nokia Mobile Secret Codes article and copy/paste in a notepad for testing

1. Log in to your blogger dashboard
2. Go to Template > Edit HTML
3. Copy the below code and paste before the </head>

<script type='text/javascript'>
function addLink() {
    var body_element = document.getElementsByTagName('body')[0];
    var selection;
    selection = window.getSelection();
    var pagelink = "<br/><br/> Original from: <a href='"+document.location.href+"'>"+document.location.href+"</a><br/>Copyright Bluesqare Tips - All Rights Reserved"; // change this if you want
    var copytext = selection + pagelink;
    var newdiv = document.createElement('div');
    newdiv.style.position='absolute';
    newdiv.style.left='-99999px';
    body_element.appendChild(newdiv);
    newdiv.innerHTML = copytext;
    selection.selectAllChildren(newdiv);
    window.setTimeout(function() {
        body_element.removeChild(newdiv);
    },0);
}document.oncopy = addLink;
</script>

You can change Copyright Bluesqare Tips - All Rights Reserved with your words and Save it

0 comments

Post a Comment