This topic is locked

Bookmark Sorted Search

10/3/2006 12:33:55 PM
PHPRunner General questions
M
mckirkus author

Is there any way to bookmark a sorted search with 3.0? In the URL I get a=advsearch but when I do an order by I get a=orderby. I doesn't seem to work when I use both. I already tweaked advanced search (using GET) to display the values in the URL but I can't figure this one out. Thanks.

J
Jane 10/4/2006

Kirk,
to use two parameters in the url open ..._list.php file, find following lines:

if(@$_REQUEST["goto"])

$_SESSION[$strTableName."_pagenumber"]=@$_REQUEST["goto"];



and add following code just before:

if(@$_REQUEST["orderby"])

$_SESSION[$strTableName."_orderby"]=@$_REQUEST["orderby"];



Then you can use something like this:

...TableName_list.php?orderby=aFieldName&a=advsearch&type=and&...



where TableName is your actual table name, FieldName is your actual field name.
This issue was added to the PHPRunner 3.1. So you can use more theb one paramaters in the url without modifying files.

M
mckirkus author 10/10/2006

Thanks but I can't find that in the code anywhere (build 113) I tried it after the 2nd if clause but that didn't work either. Here's what's in my _list.php file

if(@$action=="language")

$_SESSION["language"]=@$postvalue;

if(@$action=="orderby")

$_SESSION[$strTableName."_orderby"]=@$postvalue;

else if(@$action=="goto")

$_SESSION[$strTableName."_pagenumber"]=@$postvalue;



The problem is that if I've already searched for results and found 5 records for instance, any further searches or sorts are limited to those five records unless I click "Show All" first. Any ideas?

J
Jane 10/11/2006

Hi,
separate search works fine in the PHPRunner 3.1.

So I recommend you to upgrade your PHPRunner to 3.1.