How to add ‘nofollow’ flag to all Tag archive hyperlinks?

I already had this challenge before and here is my personal solution for you: 1. For the tag cloud widget you can use this approach: add_filter(‘wp_tag_cloud’, ‘add_nofollow_to_tag_cloud’); function add_nofollow_to_tag_cloud($content) { // Add ‘nofollow’ to the links $content = str_replace(‘<a href=”‘, ‘<a rel=”nofollow” href=”‘, $content); return $content; } I already tested this locally and it works … Read more

Remove rel=”nofollow ugc” from links in comments

This removes the tag before it displays the comment on the page. I tested it myself. function remove_ugc_from_links($text) { // replace ‘rel=”ugc”‘ with an empty string $new_text = str_replace(‘rel=”ugc”‘, ”, $text); return $new_text; } // Hook our function to the ‘comment_text’ filter add_filter( ‘comment_text’, ‘remove_ugc_from_links’);

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)