Kamis, 14 Januari 2016

Remove Active Link In Blog Comment

My Little Notes - This time i will share how to remove active link on blog comment. If uncomfortable for spam comments on blog comment, you can use this trick.

One of spam comment a recurring this where the comments there is an active link, there is even a link that is embedded in the word.


How To: Remove Active Link in Blog Comment

For remove active link there are several ways for turn off active link in blog comment, in here i will share 4 trick for remove active link in blog comment.

The First Trick For Turn Off Active Link In Blog Comment

  • Find this code </head> or use ctrl+f for simplify search
  • Copy and paste this script onto </head>   
     
    <!--Turn Off Active Link and removed--> <script src='https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js' type='text/javascript'></script> <script type='text/javascript'> $(function() { $('#comments p').find('a').remove(); }); </script>
  • And save template
    explanation : for up script are colored light blue, if in blog has available and should don't use this script
     

The Second Trick For Turn Off Active Link In Blog Comment

  • Find this code ]]></b:skin> and put this script under code ]]></b:skin> {This also code can put up </head> or <body>;
    <script src='http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js' type='text/javascript'></script> <script type='text/javascript'> $(function() { $('#comments p').find('a').remove(); }); </script>
  • Save template
  •  
    explanation : for up script are colored light blue, if in blog has available and should don't use this script

 

The Third Trick For Turn Off Active Link In Blog Comment

    This code for note of warning if active link will be included to blog comment 
    <script src='https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js' type='text/javascript'/> <script type='text/javascript'> jQuery(document).ready(function(){ jQuery("#comments p").find("a").replaceWith("<span> Dilarang menggunakan Link Aktif.</span>"); }); </script>
     
    explanation : for up script are colored light blue, if in blog has available and should don't use this script

 

The Fourth Trick For Turn Off Active Link In Blog Comment

    Put this script on <body>  

    <script type='text/javascript'> //<![CDATA[ function blockLinks(parentID, children) { var parent = document.getElementById(parentID), content = parent.getElementsByTagName(children); for (var i = 0; i < content.length; i++) { if (content[i].innerHTML.indexOf('</a>') !== -1) { content[i].innerHTML = "<mark>No live link!!!</mark> Dilarang nyepam di sini!"; content[i].className = "spammer-detected"; } } } blockLinks('comment-holder', 'p'); //]]> </script>

There is tutorial for Remove Active Link In Blog Comment, may be suggestions or ideas that you want to add or also sharing ? please add and contact me via Google+


Thanks, may be useful and happy blogging !!!

Tidak ada komentar:

Posting Komentar