We build. You grow.

Get best community software here

Start a social network, a fan-site, an education project with oxwall - free opensource community software

Make parsed newsfeed links as nofollow? | Forum

Marcus
Marcus Sep 21 '15
Hi I am not sure why rel nofollow is not added to newsfeed parsed URL. The top link is a nofollow but the logo and anchor ain't.
The Forum post is edited by Marcus Sep 21 '15
Attachments:
  21-9-2015 15.9.48 1.jpg (32Kb)
Marcus
Marcus Sep 21 '15
P.S. My version is 1.7.2
Taissa Team
Taissa Sep 23 '15
Marcus, the "nofollow" link attribute was originally created to block search engines from following external links to avoid a large amount of spam. But Newsfeed it is not the place where you can see the spam activity. Also, to create oembed links Newsfeed use the oembed third-party library,  and adding nofollow attribute to oembed links requires complex code reorganisation. According the reasons mentioned above this is not the major task.  But if you need this to be changed, you can implement it by custom code modification.

If you are not familiar with the code modification or plugin development, it would be better for you to find a developer who can help you. You can do it here: http://www.oxwall.org/market/specialists.
The Forum post is edited by Taissa Sep 23 '15
Marcus
Marcus Sep 24 '15
Ok thanks so much! i have heard that 1.7.3 version takes care of that i mean adds nofollow rel to outgoing links is it global?
Taissa Team
Taissa Sep 24 '15
Marcus, this functionality to automatically add rel="nofollow" attributes for all external links was implemented in the 1.5.3 version to discourage spam bots. But as I wrote above this not includes oembed code links.
Marcus
Marcus Sep 25 '15
Thanks so much, Do you know which file currently is creating oembed links I think I will just add nofollow rel to the default link what do you think?
Taissa Team
Taissa Sep 28 '15
Marcus, it is possible, you will need to edit /ow_plugins/newsfeed/views/formats/image_content.html file. But you should remember it may affect to other newsfeed links.
Marcus
Marcus Sep 29 '15
Thanks so much! How about this:

If ($_SERVER['SERVER_NAME'] == "my URL")
{
$rel_nofollow = "";
}
else
{
$rel_nofollow = "rel="nofollow"";
}

Maybe it's better to use jQuery?
Taissa Team
Taissa Sep 29 '15
Marcus, since this is considered as custom code modification I'll move this topic to Custom Code Modifications Forum.
Taissa Team
Taissa Sep 29 '15
Topic was moved from General Questions.