![]() |
![]() |
![]() |
||||
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() ![]() |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
![]() |
#1 |
Raise Your Weapon
Industry Role:
Join Date: Jun 2003
Location: Outback Australia
Posts: 15,601
|
Wordpress Plugin Nofollow External Links ?
Do you use a nofollow external links plugin, if so which one ? There are a few, which is the best ?
thanks in advance. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#2 |
So fuckin' bored
Industry Role:
Join Date: Jun 2003
Posts: 32,386
|
__________________
Obey the Cowgod |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#3 |
Raise Your Weapon
Industry Role:
Join Date: Jun 2003
Location: Outback Australia
Posts: 15,601
|
Any more suggestions for a nofollow external links plugin ?
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#4 |
Too lazy to set a custom title
Industry Role:
Join Date: Aug 2002
Posts: 55,372
|
dont really need a plugin, try adding this to your functions.php file in your theme
Code:
add_filter('the_content', 'my_nofollow'); function my_nofollow($content) { return preg_replace_callback('/<a[^>]+/', 'my_nofollow_callback', $content); } function my_nofollow_callback($matches) { $link = $matches[0]; $site_link = get_bloginfo('url'); if (strpos($link, 'rel') === false) { $link = preg_replace("%(href=\S(?!$site_link))%i", 'rel="nofollow" $1', $link); } elseif (preg_match("%href=\S(?!$site_link)%i", $link)) { $link = preg_replace('/rel=\S(?!nofollow)\S*/i', 'rel="nofollow"', $link); } return $link; }
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence. ![]() WP Stuff |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#5 |
So fuckin' bored
Industry Role:
Join Date: Jun 2003
Posts: 32,386
|
Modifying functions.php is not a good idea because the theme can be changed or updated. Plugin is always a better solution. Its easier to enable/disable/update/modify/remove etc.
__________________
Obey the Cowgod |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#6 |
Damn Right I Kiss Ass!
Industry Role:
Join Date: Dec 2003
Location: Cowtown, USA
Posts: 32,409
|
These are the droids you are looking for:
Nofollow Links It will show up under tools... It'll list all of your links... just check box the once you want a nofollow on... done... |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#7 |
Raise Your Weapon
Industry Role:
Join Date: Jun 2003
Location: Outback Australia
Posts: 15,601
|
Thanks everyone.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#8 | |
Too lazy to set a custom title
Industry Role:
Join Date: Aug 2002
Posts: 55,372
|
Quote:
i could understand if its a theme from the codex which will autoupdate or something like that, but if its something custom to me, i do it this way.
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence. ![]() WP Stuff |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#9 |
So fuckin' bored
Industry Role:
Join Date: Jun 2003
Posts: 32,386
|
The reason?
__________________
Obey the Cowgod |
![]() |
![]() ![]() ![]() ![]() ![]() |