Powered by Blogger.

Monday 4 March 2013

How To Add A Copyright Notice To Copied Text

Posted by Imran at 01:04
Add Copyright Notice To Copied Content
I was search for an aritcle for my assignment while copy pasting my valuable content i notice that a refrence link with that content is also appearce at the bottom of the content indicating the source, I thought that was kind of safty tip and tried to figure out how to do it. they use a service called Tynt. That’s cool and all, but I wanted to see if I could make it happen using JavaScript. All I needed my function to do was grab the copied selection, tack on a copyright notice and then add the two to the clipboard.




How To Add A Copyright Notice To Copied Text

1. Go To Blogger.com > Select Your Blog > Template
2.  Tick the box "Expand widgets templates"
3. Search for the Head ending Tag </head>
4. And Paste Just Above to Below code

<!-- Add @copyright Code During Coping By ITW (http://itwebister.blogspot.com/2013/03/how-to-add-copyright-notice-to-copied.html) -->

<script type='text/javascript'>
function addLink() {
    var body_element = document.getElementsByTagName(&#39;body&#39;)[0];
    var selection;
    selection = window.getSelection();
    var pagelink = &quot;<br/><br/> ITWebister Copyright &#169;. All Rights Reserved. Strict No Copy Policy Read more at: <a href='&quot;+document.location.href+&quot;'>&quot;+document.location.href+&quot;</a><br/> &quot;; // change this if you want
    var copytext = selection + pagelink;
    var newdiv = document.createElement(&#39;div&#39;);
    newdiv.style.position=&#39;absolute&#39;;
    newdiv.style.left=&#39;-99999px&#39;;
    body_element.appendChild(newdiv);
    newdiv.innerHTML = copytext;
    selection.selectAllChildren(newdiv);
    window.setTimeout(function() {
        body_element.removeChild(newdiv);
    },0);
}
document.oncopy = addLink;
</script>

<!-- End Add @copyright Code During Copien By ITW (http://itwebister.blogspot.com/2013/03/how-to-add-copyright-notice-to-copied.html) -->


5. Change " ITWebister Copyright. All Rights Reserved. Strict No Copy Policy Read more at:" With Your desired content.
6. do not delete "&#169;" this is copyright sign.

You Are Done.


Please Comment Your Opinion


If you enjoyed this post and wish to be informed whenever a new post is published, then make sure you subscribe to my regular Email Updates. Subscribe Now!


Kindly Bookmark and Share it:

YOUR ADSENSE CODE GOES HERE

0 comments:

Have any question? Feel Free To Post Below:

 

Popular Posts

© 2011. All Rights Reserved | ITWebister | Template by Blogger Widgets

Home | About | Top