Justtechjobs.com Find a programming school near you






Online Campus Both


php4-beta | 200004

[PHP4BETA] howto remove key/value from array based on regexp From: Dan Larsson (dl <email protected>)
Date: 04/11/00

My aim is to remove any keys where the values contain nothing but
spaces and/or newlines from an array.

$array[0] = '123';
$array[1] = ' ';
$array[2] = 'abc';

so that the above array becomes

$array[0] = '123';
$array[1] = 'abc';

Any ideas?

Regards
------------
Dan Larsson

-- 
PHP 4.0 Beta Mailing List <http://www.php.net/version4/>
To unsubscribe, e-mail: php4beta-unsubscribe <email protected>
For additional commands, e-mail: php4beta-help <email protected>
To contact the list administrators, e-mail: php4beta-admin <email protected>