On Tue, 24 Jul 2001, Markus Fischer wrote:
> I see, this coming from PHP-GTK developing ?
> 
> Can you give an example for a function that takes some fixed
> parameter (take a resource of some kind as an example) and the
> next parameter being another resource OR an array of that other
> resources ?
> 
> I'm just wondering if I can put this all into a single
> zend_parse_parameters() or if I'ld need to use some kind of if()
> statement for this one.

You will need to use something like this until [] specifiers are
implemented.

if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS(), "rr", &res1, 
&res2) == FAILURE) {
        if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS(), "ra", 
&res1, &res_arr) == FAILURE) {
                // output error message here
        }
}

-Andrei

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to