This topic is locked

filter list page

7/23/2008 3:45:36 PM
PHPRunner General questions
G
gbhmayer1 author

I would like to filter the list form (on show event, for example) to show me only the records from the date "today". I would like to keep the funcionality of the "show all" button.

A
allan 7/23/2008

You can do it by editing the SQL Query
Example,
Select

Name,

Date

FROM Table_Name

WHERE Date=Today
For the button, I would like to know too

J
Jane 7/24/2008

Hi,
use List page: Before SQL query event for this purpose.

Here is a sample:

if ($_REQUEST["a"]!="search" && $_REQUEST["a"]!="advsearch")

$strWhereClause = whereAdd($strWhereClause,"Date=CURDATE()");