On Thu, 2006-01-12 at 01:25, Jason Garber wrote:
> Hello Aidan,
>
> I think named parameters would be a useful feature... I'll leave it
> at that.
>
> Here is a coding idea for you, in case you hadn't considered it...
>
> function highlight($text=NULL, $needle=NULL, $strip_links=NULL, ...)
> {
> is_null($text) && $text = SOME DEFAULT VALUE;
> is_null($needle) && $text = SOME DEFAULT VALUE;
> is_null($strip_links) && $text = SOME DEFAULT VALUE;
> ...
> }
Ummmmm, how is that different (ignoring the copy paste bugs in the &&
$text parts) than:
function highlight
(
$text=SOME DEFAULT VALUE,
$needle=SOME DEFAULT VALUE,
$strip_links=SOME DEFAULT VALUE,
...
)
{
...
}
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