Blogger Themes

Sunday, 11 December 2011

How to automatically add copyright when someone copies your articlesin blogger


Hello Everyone

First of all I would like to thank Ashiq Hassan for this article in his blog.
Ok now for the article.
Take a quick demo here :http://demo-onlinetrick.blogspot.com/2011/11/copy-some-of-article-and-paste-on.html
Whenever you copy it you get this Copyright Geekspot.in - All Rights Reserved
Thanks Ashiq Hassan
Now here is the tut.
Go to blogger->Design->edit html
Find </head>
And before it add the following code.
<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 Geekspot.in - 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>




Change Copyright Geekspot.in - All Rights Reserved if you want.
Thanks for viewing. :)
Share on :

1 comments:

ratownik medyczny said...

I think other web-site proprietors should take this web site as an model, very clean and excellent user genial style and design, let alone the content. You're an expert in this topic!

Post a Comment

 
© Copyright TechRio 2011 - Some rights reserved | Powered by Blogger.com.
Template Design by Herdiansyah Hamzah | Published by Borneo Templates and Theme4all