RSS Follow us on Google+ Follow us on Twitter! Follow us on Facebook! Follow us on Linkedin!

Attention

Permohonan maaf

Mohon maaf yang sedalam-dalamnya kepada seluruh pengunjung Blog AsalNy@mbung dikarenakan Blog masih dalam modifikasi jadi seluruh konten atau artikel belum tertata secara benar, baik tampilan maupun designnya, sekali lagi admin AsalNy@mbung Mohon maaf. dan terimaksih banyak sudah berkunjung, salam sukses selalu untuk sahabat blogger semuanya.

Home » » Automatically Remove Links From Blogger Comments With jQuery

Automatically Remove Links From Blogger Comments With jQuery

Written By Unknown on Friday, April 5, 2013 | 9:26 PM

One way of combating spammers in your Blogger blog’s Comments section is by preventing the use of HTML-based codes that enables the embedding of hyperlinked texts. This would be no problem if you’re using a third-party commenting system like Disqus or Intense Debate that gives its users the option to disable embedding of HTML code.
But what if you want to stick with Blogger’s default commenting system? Well, fortunately there’s Nitin Maheta, a Blogger user who was kind enough to share a tutorial that’ll teach you how to give Blogger’s commenting system the same feature by turning links into simple text. All takes is using a little bit of jQuery. Just simply follow the instructions below.
  • In your Blogger dashboard, head over to Design and then on Template.
  • Click on Edit HTML.
  • Search for the </body> tag and then copy/paste the code below just right above it.
<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>     
NOTE: If you already have the part that’s highlighted in red already in your template’s code then exclude it and just copy the remainder of the code.
  • Save your template and you’re done. By pasting the above code in your template, all the hyperlinked text in a comment will be converted to simple [unclickable] text.
OR, if you’d rather have the hyperlinked texts removed entirely than just disabling the hyperlinked text, then copy/paste this code below instead. Again, if you already have the one that’s highlighted in red inside your template’s code then just skip copying that part.
<script src='https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js'/>
<script>$('.comment-content a[rel$=nofollow]').hide());</script> 
  • Save your template and that’s it. You’re done!
Share this article :

0 comments:

Post a Comment

Terimakasih atas kunjungannya
Demi Perubahan Blog Ini Ke Arah Lebih Baik Saran Agan-Agan Sangat Bermanfaat, Terimakasih......!!!

 
Support : Kolom Tutorial™ | MPI. Al-Munfardiyyah
Copyright © 2013. Asal Ny@mbung - All Rights Reserved
Template Created by Creating Website Published by Mas Template
Proudly powered by Blogger