* Thus wrote Justin French:
> On 12/07/2004, at 6:38 PM, Thomas Seifert wrote:
> 
> My view of internal functions is that they solve common, repetitive 
> problems.  Sure, some of those problems are quite complex, but others 
> are not.  A perfect example would be array_walk() -- it can be solved 
> in a "one liner" too:
> 
>       foreach ($in as $k => $v ) { $in[$k] = myFunction($v); }
> 
> ... but someone decided it was useful as an internal function.  My hope 
> was that there was such a function to delete empty array elements 
> already defined in PHP, but since it appears there isn't, I'll just 
> keep including my own from a library file.

The problem with your function you want is that it is very
specific, the name would have to be something like:

  unset_array_items_only_if_val_is_empty($array);


Curt
-- 
First, let me assure you that this is not one of those shady pyramid schemes
you've been hearing about.  No, sir.  Our model is the trapezoid!

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

Reply via email to