Remove links from blogger comments automatically

Remove links from blogger comments automatically

remove spam from blogger comments


Every blogger have a problem with spammers who send spam to your blogger comments ,Blogger give us no control over links in commenting system , to remove links from blogger comments automatically here is a way to get rid of spam and spammers with no pain 

1- Hide comment links using css

Add this code to the CSS

.comment-content a {
    display: none;
}

2- hide comments links using javascript


a) Transform Links into Text  

 If you just wanna transform links into text and do not want to remove them , copy the following code and paste it just above the </body> tag in your blogger's Edit HTML,

    <script src='https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js'/>
    <script>$('.comment-content a[rel$=nofollow]').replaceWith(function(){return ($(this).text());});</script>

b) Removing Links from comments

 Well if you do not wanna transform links into plain text but just want to remove them tottaly then paste the below code above </body> tag.
    <script src='https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js'/>    <script>$('.comment-content a[rel$=nofollow]').hide());</script>

c) Remove Older Blogger Commenting System links

 If you are still using old blogger commenting system then the above code will not work for your website you can try the below code instead  </body> tag.
<script src='https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js'/>
<script>$('.comment-body p a[rel$=nofollow]').replaceWith(function(){return ($(this).text());});</script>


Notice  if you already have jQuery installed remove the orange line.


Now you don`t have to remove spam links manually again feel free to send your comment discussion is not closed yet ;)

Remove links from blogger comments automatically
4/ 5 stars - "Remove links from blogger comments automatically"