Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

Re: [Andy] Need help with 2.2.0 changes for "isValidated"

Quote Reply
Re: [Andy] Need help with 2.2.0 changes for "isValidated" In reply to
Thanks for the help guys... Fortunately I think I may have found the problem and a solution.

I found that isValidated=Yes was no working as a valid search field because of this code in the search.pm :

# Remove search fields we aren't allowed to search on.
my @bad = (@{$CFG->{search_blocked}}, qw/isValidated ExpiryDate/);


You'll notice how isValidated is being blocked as a valid search. Guess that was added to work with the new payment modules. Althought it looks to me like there is really no reason it should have been blocked.

Doesn't this code located a few lines below eliminate any search results that have expired???

# Make sure we only search on validated links.
$IN->param('isValidated', 'Yes');
$IN->param('ExpiryDate', '>=' . time) if $CFG->{payment}->{enabled};


Besides, even if you were not using "isValidated" as a search field you are still going to run into problems. Lets say you wanted to search on a certain field.... EX: http://www.mysite.com/cgi-bin/links/search.cgi?query=&isPopular=Yes

Give it a try and you'll notice that the urls of the page spans are being created with isValided=Yes added in there. Since it is blocked in 2.2.0 those span pages will no longer work. EX: http://www.mysite.com/...lidated=Yes&nh=2

Better check your sites people... I didn't notice this for weeks.

Here's the line I changed in search.pm to my problem...

my @bad = (@{$CFG->{search_blocked}}, qw/isValidated ExpiryDate/);

to

my @bad = (@{$CFG->{search_blocked}}, qw/ExpiryDate/);


I'm not using the payment modules yet so this works fine for me. I'd would like to find that this has on adverse affect on them since I do plan on accepting payments in the future. Hopefully someone can confirm this and hopefully GT can make changes as well since there is a definate problem with the page spans.

Later
Subject Author Views Date
Thread Need help with 2.2.0 changes for "isValidated" Jonze 3288 May 27, 2004, 5:58 PM
Post Re: [Jonze] Need help with 2.2.0 changes for "isValidated"
pugdog 3220 May 30, 2004, 4:46 PM
Thread Re: [Jonze] Need help with 2.2.0 changes for "isValidated"
Andy 3210 May 31, 2004, 12:49 AM
Thread Re: [Andy] Need help with 2.2.0 changes for "isValidated"
Jonze 3171 Jul 1, 2004, 10:27 AM
Thread Re: [Jonze] Need help with 2.2.0 changes for "isValidated"
Jagerman 3151 Jul 1, 2004, 3:09 PM
Post Re: [Jagerman] Need help with 2.2.0 changes for "isValidated"
Jonze 3138 Jul 2, 2004, 9:16 AM