On Tue, 2005-06-14 at 01:31, Ron Korving wrote:
> Jason, you are absolutely right.. this is not about input filtering at all.
> It's about replacing:
> 
> $x = (isset($ANY_var) ? $ANY_var : 'Default Value');
> by
> $x = ifsetor($ANY_var, 'Default Value');
> 
> So, Robert's solution is no real solution if you ask me. But again, it would
> be best, if there was no ifsetor() at all, but that users would have the
> power to create such a function themselves in the php code space. I have no
> clue how though...

Well my code has nothing to do with filtering. It's all about retrieving
a default value if one is not set in response to the poster to which I
replied. But yes, I was hasty with it in my eternal lack of wisdom, and
of course forgot about scalars. For the record, I am indeed in favour of
something that allows the choice of a value from a series of values for
which some may not be set-- without the generation of not set warnings
:)

On that note, how comes there's a $GLOBAL array and not a $LOCAL array
for vars declared in the immediate scope :)

Cheers,
Rob.
-- 
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com |
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting  |
| a powerful, scalable system for accessing system services  |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for       |
| creating re-usable components quickly and easily.          |
`------------------------------------------------------------'

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to