Make blogroll links nofollow

When linking from your website to another, you can add the “nofollow” attribute to the link to prevent Google’s Web crawling robot from following the link.Adding this PHP code to the functions.php will make add nofollow to all blogroll bookmarks.



function no_follow( $links ) {
foreach($links as $link) {
$link->link_rel .= ' nofollow';
$link->link_rel = trim($link->link_rel);
return $links;
add_filter('get_bookmarks', 'no_follow');

Leave a comment