Bug #15574 Updated: Strip out array keys with no value

From: Date: Fri, 15 Feb 2002 17:38:45 +0000
Subject: Bug #15574 Updated: Strip out array keys with no value
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-374@lists.php.net to get a copy of this message
ID: 15574 Updated by: cynic@php.net Reported By: zakstergrant@hotmail.com Status: Bogus Bug Type: Feature/Change Request Operating System: Linux Mandrake 8.2b2 PHP Version: 4.1.1 New Comment: just in case you were wondering why your question was a support stuff: eliminating empty values from an array is a one-liner with today's capabilities. no reason to add this function. Previous Comments: ------------------------------------------------------------------------ [2002-02-15 12:36:34] cynic@php.net The bug system is not the appropriate forum for asking support questions. For a list of a range of more appropriate places to ask for help using PHP, please visit http://www.php.net/support.php ------------------------------------------------------------------------ [2002-02-15 12:28:53] zakstergrant@hotmail.com Is it possible to add a function which strips out all parts of an array which don't have a value? I ask this simply because I'm trying to array_diff a submitted form against a set of required fields, and my test machine (Win2K/IE5) sends all empty form elements over in an array (I use NAME="FormData[Bar]", NAME="FormData[Baz]", etc) with empty values, and PHP puts them into my form array. It'd be great if I could say "array_strip_empty($myarray)" and PHP took out all values which are "" (empty) Thanks, ~ZG~ ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=15574&edit=1

« previous php.bugs (#374) next »