Choose your database:
AnySQL
MySQL
MS SQL Server
PostgreSQL
SQLite
Firebird
Oracle
SQL Anywhere
DB2
MaxDB

Subscribe to our news:
Partners
Testimonials
Steve Morton: "First let me thank you for making this application Free. Best deal I have ever see for what it does".
Kirby Foster: "Nice software. Small, lightweight, works well. I evaluated lots of software before deciding that your software worked the best for what I do. Both Maestro for MySQL and PHP Generator have saved me lots of time".

More

Add your opinion

PHP Generator for MySQL online Help

Prev Return to chapter overview Next

OnGetSelectionFilters

This event allows you to specify a set of pre-defined options for record selection.

 

Signature:

function OnGetSelectionFilters(FixedKeysArray $columns, &$result)

 

Parameters:

$columns

An associative array of columns available for filtering.

$result

An associative array of selection options (caption => filter)

 

Example

 

This example adds "Americas", "Asia+Africa", and "Europe" selection options. Clicking an option selects the corresponding countries.

 

$result = array(

    'Americas' => new FilterCondition(

        $columns['continent'],

        FilterConditionOperator::ENDS_WITH,

        array('America')

    ),

    'Asia+Africa' => new FilterGroup(FilterGroupOperator::OPERATOR_OR,

        array(

            new FilterCondition($columns['continent'], 

                       FilterConditionOperator::EQUALS, array('Asia')),

            new FilterCondition($columns['continent'],

                       FilterConditionOperator::EQUALS, array('Africa'))

        )

    ),

    'Europe' => new FilterCondition(

        $columns['continent'],

        FilterConditionOperator::EQUALS,

        array('Europe')

    ),

);



Prev Return to chapter overview Next