Thursday, September 24, 2020
Home Blogging Tips & Tweaks How to Disable Right Click Option on Specific Blogger Posts

How to Disable Right Click Option on Specific Blogger Posts

Disabling right click option is an important feature to add to an entertainment blog to help fight against plagiarism as it prevents content thieves from copying texts easily from the blog. As a technical blog owner, it is not advisable to add this because you will be denying your readers access to long chunk of codes which they won’t have the time to write out.

Previously, I showed you how to disable text copying from your whole blog. Today I want to show how to disable the right click option in your individual posts. The code we will be using will help you disable the right click option on parts of your blog posts that does not contain images. What I mean is that the code can only prevent texts selection in your post but readers might be able to copy images on the post.

One good thing to note about this code that seems to make it better than the one I showed you in the tutorial on Disabling Text Copying From Blogger Posts is that you will be able to specify which post you want your readers not to be able to use the right click option on.

Adding this code to your blog is very easy and depends on the type of post you intend adding it to. As I mentioned earlier, the code is used for individual posts and is not suitable for posts that does require the reader to copy a specific chunk of codes. So if you are running a blog that focuses on providing HTML, CSS, JavaScript, XML, etc. tutorials, I don’t encourage you to make use of it (the code) as you will be making it difficult for your readers to copy and test the codes you might be using as examples. With that said, here is the tutorial on how to add it to any post of your choice.

How to Disable Right Click Option on Blogger Page :

Now here is how the code is added to blog posts to help disable the Right Click Option

  • Login into your Blogger dashboard
  • Click on Posts
  • Locate the post you wish to disable the right click option on and click on Edit
  • When the post editing page opens, navigate to its HTML mode
  • Scroll to the end of the post’s HTML mode
  • Copy the code shown below and paste just immediately after the post’s HTML codes (i.e. at the end)
<style type='text/css'>
.post-body {
  -webkit-user-select: none;  /* Chrome all / Safari
all */
  -moz-user-select: none;     /* Firefox all */
  -ms-user-select: none;      /* IE 10+ */
  -o-user-select: none;
  user-select: none;
  • Click on Update

With that done, no reader will be able to copy any text from the post since the right click option should have been disabled.

For newer posts, when done composing the post, switch to HTML mode and paste the above code snippet below the composed post’s HTML code.

Note: This code might not be supported in some browser but have been tested in most of the popular browsers and is working.


Please enter your comment!
Please enter your name here

Most Popular

List of All JavaScript Arithmetic Operators With Examples

JavaScript offers several operators to help us work with numbers. All these operators are binary operators, which means they operate on two operands. The operands...

How to Find a Website’s RSS Feed’s URL

Having access to the RSS feed of a website gives you the opportunity to stay up-to-date on everything that website publishes. Whether that’s a...

Laravel: String data, right truncated: 1406 Data too long for column (SOLVED)

I was working on a project today when i ran into the error message "String data, right truncated: 1406 Data too long for column...

How to Enable or Disable Chrome’s Autofill on Android Devices

Storing your login details and other information in Chrome and/or your Google Account isn’t as secure as using an encrypted password manager, but it’s...

Recent Comments