Not Solved nofollow links all external
#1
Not Solved
hi,

How all  site exit links external set to nofollow?

thaks
_______________________________________________

It is not disgraceful to ask, it is disgraceful no to ask.


sory for my english .
Reply
#2
Not Solved
I guess it is still working http://mods.mybb.com/view/nofollowexternal
[Image: cafaf18ba2.gif]
FileSquid is under development
[Image: trk1]
Reply
#3
Not Solved
Thanks wery much,
but after activate plugin sql eror login threads and posts,how fix it?

thanks


Hata Tipi:
Uyarı (2)
Hata Mesajı:
preg_match(): Unknown modifier '/'
Konum:
Dosya: inc/plugins/nofollowexternal.php
Satır: 30
Kod:
27.     global $mybb;
28.     $url = preg_quote($mybb->settings['bburl']);
29.     $urls = preg_replace("/^http:/","https:", $url, 1);
30.     if (preg_match("/$url/", $groups[1]) || preg_match("/$urls/", $groups[1])) {
31.         return $groups[0];
32.     }
33.     else {


(2015-12-13, 04:25 PM)Dark-Power-Invader Wrote: I guess it is still working http://mods.mybb.com/view/nofollowexternal
_______________________________________________

It is not disgraceful to ask, it is disgraceful no to ask.


sory for my english .
Reply
#4
Not Solved
If you use Google SEO plugin, there is an option under settings that will allow you to nofollow links in posts.
What goes around comes around
Reply
#5
Not Solved
(2015-12-13, 08:14 PM)Ashley1 Wrote: If you use Google SEO plugin, there is an option under settings that will allow you to nofollow links in posts.

yes i use gogle seo,other idea nofollow for internal links?
_______________________________________________

It is not disgraceful to ask, it is disgraceful no to ask.


sory for my english .
Reply
#6
Not Solved
Are there areas of your site you want to nofollow ? Try using a meta noindex tag directly on those pages.
What goes around comes around
Reply
#7
Not Solved
Hi roy.
plugin nofollowexternal has the bugs  Sad


A manual solution edit file class_parser.php


My cod for 1.6.x
		// Fix some entities in URLs
		$entities = array('$' => '%24', '$' => '%24', '^' => '%5E', '`' => '%60', '[' => '%5B', ']' => '%5D', '{' => '%7B', '}' => '%7D', '"' => '%22', '<' => '%3C', '>' => '%3E', ' ' => '%20');
		$fullurl = str_replace(array_keys($entities), array_values($entities), $fullurl);

		$name = preg_replace("#&amp;\#([0-9]+);#si", "&#$1;", $name); // Fix & but allow unicode
// wstawka modyfikująca zewnętrzne linki w postach oraz www stronach uzytkownika przy posyach na nofollow
		
		// $link = "<a href=\"$fullurl\" target=\"_blank\" rel=\"nofollow\">$name</a>";
                // nie zmieniamy na nofollow linków do nas!!!
                $_host = '://'.$_SERVER["HTTP_HOST"];
                // ://mojastrona.pl jest w URL-u
                // i zaczyna sie nie dalej niż na 5 miejscu (https ma 5 znaków)
                if((strpos($fullurl,$_host) !== FALSE) && (strpos($fullurl,$_host) < 6))
                {
                  // Parse internal URL
                  $link = "<a href=\"$fullurl\" target=\"_blank\">$name</a>";
                } else {
                  // linki do mojej domeny!!! Chcemy miec follow!!!
                  $_host_moj = '://mojastrona.pl';
                  if((strpos($fullurl,$_host_moj) !== FALSE) && (strpos($fullurl,$_host) < 6))
                  {
                    // Parse internal URL
                    $link = "<a href=\"$fullurl\" target=\"_blank\">$name</a>";
                  } else {
                    // Parse external URL deferred by anonym.to and with rel="nofollow"
                    // $link = "<a href=\"http://anonym.to/?$fullurl\" target=\"_blank\" rel=\"nofollow\">$name</a>";
                    $link = "<a href=\"$fullurl\" target=\"_blank\" rel=\"nofollow\">$name</a>";
                  }
                  unset($_host_moj);
                }
				
				unset($_host);
// koniec mojej wstawki
		return $link;
	}

	/**
	* Parses URL MyCode.


Edit the file with MyBB 1.8

		// Fix some entities in URLs
		$entities = array('$' => '%24', '$' => '%24', '^' => '%5E', '`' => '%60', '[' => '%5B', ']' => '%5D', '{' => '%7B', '}' => '%7D', '"' => '%22', '<' => '%3C', '>' => '%3E', ' ' => '%20');
		$url = str_replace(array_keys($entities), array_values($entities), $url);

		$name = preg_replace("#&amp;\#([0-9]+);#si", "&#$1;", $name); // Fix & but allow unicode
		$link = "<a href=\"$url\" target=\"_blank\"{$nofollow}>$name</a>";
		return $link;
	}

	/**
	* Parses URL MyCode.


Lightbulb  1.6= $fullurl in 1.8= $url

External links then have: nofollow (posts and threads forum)

Good luck
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)