How to Disable Copy Function On Blogger with CSS or JavaScript (Updated)

Hello and Welcome to GetWebInfo.Com. Here you can learn how to disable the Copy Function on Blogger with CSS or JavaScript. Most of the real bloggers on BlogSpot Platform are the problem of their blog's content being copied or duplicated by newbies who are just entering into biosphere with real efforts without money and understanding of the original content. Sometimes the content is copied by search engines in their original content rather than the actual content and it is unfair which is the real bloggers of motivation. So it is important to protect your blogger content from these content thieves and this is the post of this post. We will disable the copy function by disable the mouse right click and CTRL + A. We have the option for doing this. Via a JavaScript Code If you want to use the entire text area of blog or through CSS code if you share some code / text on your blog posts and your readers need them to copy.

Hello and Welcome to GetWebInfo.Com. Here you can learn how to disable the Copy Function on Blogger with CSS or JavaScript. Most of the real bloggers on BlogSpot Platform are the problem of their blog's content being copied or duplicated by newbies who are just entering into biosphere with real efforts without money and understanding of the original content. Sometimes the content is copied by search engines in their original content rather than the actual content and it is unfair which is the real bloggers of motivation. So it is important to protect your blogger content from these content thieves and this is the post of this post. We will disable the copy function by disable the mouse right click and CTRL + A. We have the option for doing this. Via a JavaScript Code If you want to use the entire text area of blog or through CSS code if you share some code / text on your blog posts and your readers need them to copy.


Benefit of Using CSS Code rather than JavaScript

1) When we use JavaScript code, do you know what a copy cat does? Simply disables
JavaScript code inside browser and reload the page. Then everything goes in normal
and anyone can copy the entire content.

Using CSS code we can use this theme as the user usually does not have the CSS.
However, an experienced user can simply inspecting the elements by doing it and ours
CSS code snippet then delete it in browser but this task is very far from newbies.
Experienced users rarely do that.

2) CSS codes are far better than JavaScripts as they do not lower the speed of your
Blog / website where JavaScript codes consume more time to load and create your blog

load speed very low and overall you lose visitors = money. Avoid using JavaScripts.





Disable Text Selection On Blogger With JavaScript Code

Step 01: Go To Blgger> Template> Edit Template> Backup your Template Code First

Step 02: Now Search for <head> and copy paste the JavaScript Code given below after <head> tag
<!--Disabe Copy Paste--- GetWebInfo-->
<script language='JavaScript1.2'>
function disableselect(e){
return false
}
function reEnable(){
return true
}
document.onselectstart=new Function (&quot;return false&quot;)
if (window.sidebar){
document.onmousedown=disableselect
document.onclick=reEnable
}
</script>

Disable Text Selection Except Specified Codes/Text With CSS

This is the Magic code we are using on this blog because we are sharing tutorials where readers need to copy some codes we share like CSS/JavaScript/HTML etc. So on the same time we do not let readers copy our posts text area other than codes/Text we want to share. This is possible with this simple CSS code where enabled the copy paste of Text/Code we post in "Blockquotes" only. Go to Blogger> Template> Edit Template> Backup.

Now Search for ]]></b:skin> this code line and copy paste the CSS code given below before this ]]</b:skin> code line.

/*----- Disable Text Selection with CSS Code--- GetWebInfo----*/
.post blockquote {
-webkit-user-select: text !important;
-moz-user-select: text !important;
-ms-user-select: text !important;
user-select: text !important;
}
body {
-webkit-user-select: none !important;
-moz-user-select: -moz-none !important;
-ms-user-select: none !important;
user-select: none !important;
}
Important Note: In the above CSS code we have enabled the copy/selection of Text or any type of code we post using blockquotes by enabling .post blcokquote but it may not work for you if your template is using different CSS class for blockquote for etg. Our template using .post blcokquote where your template may be using .post-body blcokquote or blockquote in above CSS code. If you do not share any codes or content than just copy paste this little piece of CSS code to disable all text area on your blog.
/*----- Disable Text Selection with CSS Code--- GetWebInfo----*/
body {
-webkit-user-select: none !important;
-moz-user-select: -moz-none !important;
-ms-user-select: none !important;
user-select: none !important;
}
Note: You can add CSS codes by simply going to Template Designer>> Add Custom CSS and paste your code then Save your Template.



Let us know where these codes work for you or you are having problems with these codes? We will serve you our best. I Hope this article is really helful for you if you like this article so please share it to your Social media accounts .Thanks

Hello and Welcome to GetWebinfo.com. Here on this site you can be able to find out Latest Articles are about Blogger, SEO, AdSense, WordPress,. You can also be able to find out Latest Tips that can you really need one. You can also Download Premium themes free from this site.