Hi Tijnema,

Wednesday, June 13, 2007, 2:42:28 PM, you wrote:

> Nice one, but you could also do it like this:

> <?php
> $filter['flags'] = FALSE;

> if ($allow_fraction)
> {
>    $filter['flags'] = $filter['flags'] | FILTER_FLAG_ALLOW_FRACTION;
> }

> if ($allow_thousand)
> {
>    $filter['flags'] = $filter['flags'] | FILTER_FLAG_ALLOW_THOUSAND;
> }

> if ($allow_scientific)
> {
>    $filter['flags'] = $filter['flags'] | FILTER_FLAG_ALLOW_SCIENTIFIC;
> }

?>>

> Little bit simpler huh?

Yup.. even nicer, I'm using that method now :)

Cheers,

Rich
-- 
Zend Certified Engineer
http://www.corephp.co.uk

"Never trust a computer you can't throw out of a window"

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to