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

POST search_results hook doesn't work

Quote Reply
POST search_results hook doesn't work
I have a pre and post hook on search results...
Code:
$mgr->install_hooks('ZipCodeSearch', [['search_results', 'PRE', 'Plugins::ZipCodeSearch::search_results_hook', '']]);
$mgr->install_hooks('ZipCodeSearch', [['search_results', 'POST', 'Plugins::ZipCodeSearch::search_results_post', '']]);

In the PRE, I change query, but save the original query like this
Code:
$IN->param('orig_query', $query);
$IN->param('query', '12345 53142 60601');


Then in POST, I try to restore it so that the message on the search results page is correct and doesn't have a big long list of ZipCodes
Code:
$IN->param('query', $IN->param('orig_query'));


Doesn't work. The POST routine is not being called at all
What am I doing wrong?

I must be the only one working today as all the posts are mine.

Chris
RGB World, Inc. - Software & Web Development.
rgbworld.com