We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

NoFollow Plugin and Whitelist

Development and Programming

mayest's avatar
mayest
293 posts
17 years ago
mayest's avatar mayest

I started using the No Follow plugin a couple weeks ago for blog comments. It works great, except that it seems to ignore my whitelist. I think I’m using it correctly. Here is slightly stripped version of what I’m doing:

{exp:no_follow whitelist="y"}
{comment}
{/exp:no_follow}

I added a URL that had been posted in a comment to the whitelist, but it still shows up nofollowed in the source.

This plugin was created in January 2005, so I’m wondering if there have been some database changes that have disabled the whitelist support in this plugin? I’m using EE 1.63.

       
secondlamppost's avatar
secondlamppost
22 posts
16 years ago
secondlamppost's avatar secondlamppost

I am having a similar issue with the No Follow plugin not excluding designated groups. I have tried to exclude 2 groups URL’s using the parameter “group”. Here is my code:

{exp:comment:entries sort="asc" weblog="blog|prof_ergo"}
<div class="{switch="comment_list|comment_list_alt"}">
    {exp:no_follow group="1|6"}
        {comment}
    {/exp:no_follow}
    By {name} on {comment_date format="%M %d, %Y"}
</div><!-- closing .comment_list div -->
{/exp:comment:entries}

I have tried excluding groups using the group ID and using the group name without any results. Every link in my comments regardless of who posted them receives rel=”no_follow” attributes.

I have also tried conditionals like this:

{exp:comment:entries sort="asc" weblog="blog|prof_ergo"}
<div class="{switch="comment_list|comment_list_alt"}">
    {if member_group == "1|6"}
        {comment}
    {if:elseif group != "1|6"}
    {exp:no_follow whitelist="n"}
        {comment}
    {/exp:no_follow}
    {/if}
    By {name} on {comment_date format="%M %d, %Y"}
</div><!-- closing .comment_list div -->
{/exp:comment:entries}

But I received the same results. Am I misusing this plugin? I found little in the forums regarding using it. Or alternately, is there a better plugin that would accomplish the same thing?

       
applepie23's avatar
applepie23
20 posts
16 years ago
applepie23's avatar applepie23

I needed this to work so on line 111 I changed this:

if ($whitelist == 'y' && $DB->table_exists('whitelisted'))

to

if ($whitelist == 'y' && $DB->table_exists('exp_whitelisted'))

Yay.

       
mayest's avatar
mayest
293 posts
16 years ago
mayest's avatar mayest

Well, that seems to make sense. The next line of code is clearly constructing a query to pull data from the exp_whitelisted table. I’ll give this a shot. Thanks.

Yup, that seems to do the trick.

       
secondlamppost's avatar
secondlamppost
22 posts
16 years ago
secondlamppost's avatar secondlamppost

Thanks Applepie23. I abandoned this after not getting a response and not being able to find the answer. I’ll give it a try and let you know how it turns out.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.