note 95857 added to function.array-filter
| From: | alan dot lake at lakeinfoworks dot com | Date: | Tue, 26 Jan 2010 13:19:03 +0000 |
| Subject: | note 95857 added to function.array-filter | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-165309@lists.php.net to get a copy of this message | ||
Example 2, array_filter without callback, might well have included the empty array because it will
return false.
<?php
$entry = array(
0 => 'foo',
1 => false,
2 => -1,
3 => null,
4 => '',
5 => array()
);
print_r(array_filter($entry));
?>
----
Server IP: 80.81.171.181
Probable Submitter: 91.156.160.56
----
Manual Page -- http://www.php.net/manual/en/function.array-filter.php
Edit -- https://master.php.net/note/edit/95857
Del: integrated -- https://master.php.net/note/delete/95857/integrated
Del: useless -- https://master.php.net/note/delete/95857/useless
Del: bad code -- https://master.php.net/note/delete/95857/bad+code
Del: spam -- https://master.php.net/note/delete/95857/spam
Del: non-english -- https://master.php.net/note/delete/95857/non-english
Del: in docs -- https://master.php.net/note/delete/95857/in+docs
Del: other reasons-- https://master.php.net/note/delete/95857
Reject -- https://master.php.net/note/reject/95857
Search -- https://master.php.net/manage/user-notes.php