![]() |
Sergey Kornilov admin 7/16/2007 |
Use No records on the first page option on SQL query tab in PHPRunner. |
F
|
Frink09 author 7/19/2007 |
Use No records on the first page option on SQL query tab in PHPRunner.
|
F
|
Frink09 author 7/25/2007 |
Hi, I've already checked off that option on the SQL query tab. When I go to the search page there are no records displayed however the problem is when I click the search button all the records are displayed.
|
![]() |
Sergey Kornilov admin 7/25/2007 |
This behavior is by design. function BeforeQueryList(&$strSQL) |
F
|
Frink09 author 8/21/2007 |
This behavior is by design. Search button with no parameters and Show all button are used to display all records in the database. There are many ways to prevent the whole content of the database from being displayed. In PHPRunner 4.1 you can use "Before SQL query" event and the following code: function BeforeQueryList(&$strSQL) |
F
|
Frink09 author 8/28/2007 |
|
![]() |
Alexey admin 8/29/2007 |
Try using this code in Before SQL query event: if(!count($_GET) && !count($_POST) || @$REQUEST["SearchFor"]=="") $strSQL = AddWhere($gstrSQL,"1=0"); |
F
|
Frink09 author 8/29/2007 |
Try using this code in Before SQL query event:
|
![]() |
Alexey admin 8/29/2007 |
Sorry, my fault. global $gstrSQL; if(!count($_GET) && !count($_POST) || @$_REQUEST["a"]=="search" && @$REQUEST["SearchFor"]=="") $strSQL = AddWhere($gstrSQL,"1=0"); |
F
|
Frink09 author 8/29/2007 |
Sorry, my fault. Try this one:
|
R
|
Rigmantas 2/17/2008 |
I had to tweak one little thing with your code (it's in blue) and now it works! Thanks so much for the help, (and the future help to come hehe), you guys rock!!! @$REQUEST["a"]=="search" && @$****REQUEST["SearchFor"]=="")
|
J
|
Jane 2/18/2008 |
Rimantas, global $gstrSQL; if(!count($_GET) && !count($_POST) || @$_REQUEST["a"]=="search" && @$REQUEST["SearchFor"]=="" || @$_REQUEST["a"]=="advsearch" && @$_REQUEST["value_FieldName"]=="") $strSQL = AddWhere($gstrSQL,"1=0");
|