How to Delete all Active Links in a Post

How to Delete all Active Links in the Post in Blogger

I honestly don't understand why anyone will want to delete all the links in their blog post. If everything leads to the outside (external) it can still be understood, maybe so that visitors do not run away after clicking the link. But what about internal links? That's good for SEO.

Alright. Since this is a request, so I will still make the tutorial. Do you know the reason for wanting to deactivate the link? Please leave a comment.

Script to delete all URLs in the post

Before using this, make sure you have specific goals and understand the risks after disabling all active links. You just don't need to go along with it.

There are two versions, Javascript and jQuery. CHOOSE ONE, which is preferred. Can be used both on Blogger and Wordpress. Just adjust the name of the HTML element id or class.

Example: the class name is .post-body. If it turns out that in your Blogger or WordPress template it's different, just change to the name you use.


    /* Remove All Links Inside Posts by */
(function ignielRemLinkPost(){
 if (document.querySelector('.post-body')){
  var a = document.querySelectorAll('.post-body a');
  for (var x = 0; x < a.length; x++){
   var b = a[x].text, c = a[x].parentNode, d = document.createElement('span'); d.innerHTML = b;


    /* Remove All Links Inside Posts by */
window.onload = (function ignielRemLinkPost(){
 if ($('.post-body')){
Done. If successful, all active URLs in the article content will disappear and change to plain text.

Read Also

Post a comment