It's always a good idea to protect blog content from copy and paste bloggers, and this make us to write on how to disable highlight function and how to disable right click context menu on images. But i think i need to provide something more outstanding, so 1 will be sharing with you, how you can add copyright notice to copied text of your blog. But it only works with all major browser except internet explorer.
This is how it works. When someone copied your blog content and paste it any anywhere, the script will add a link back to your site as the original source with a copyright notice. Sounds cool, right?
This is how it works. When someone copied your blog content and paste it any anywhere, the script will add a link back to your site as the original source with a copyright notice. Sounds cool, right?
If you are on Wordpress you can use iCopyright or add the following code into your bloghead section. But for blogger follow the below steps.
How to Add Copyright Notice to Copied Text
- Go to your blogger dashboard
- Click on Template > Edit HTML > Proceed (Mark/Tick Expand Widget Template)
- Use ctrl F to find </head> and paste the following code above it.
<!-- Copyright Notice By RealcomBiz.com -->
<script type='text/javascript'>
function addLink() {
var body_element = document.getElementsByTagName('body')[0];
var selection;
selection = window.getSelection();
var pagelink = "<br/><br/> Read more at: <a href='"+document.location.href+"'>"+document.location.href+"</a><br/>Copyright © RealcomBiz"; // You can change this to your prefered text
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>
<script type='text/javascript'>
function addLink() {
var body_element = document.getElementsByTagName('body')[0];
var selection;
selection = window.getSelection();
var pagelink = "<br/><br/> Read more at: <a href='"+document.location.href+"'>"+document.location.href+"</a><br/>Copyright © RealcomBiz"; // You can change this to your prefered text
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 the above highlighted line to your own preferred copyright text.
- Save your template. Done!
No comments: