note 99429 added to function.is-array
| From: | cws1989 at gmail dot com | Date: | Tue, 17 Aug 2010 07:14:01 +0000 |
| Subject: | note 99429 added to function.is-array | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-171757@lists.php.net to get a copy of this message | ||
Note that in the following case, other than returning false, it will also produce an E_NOTICE
<?php
error_reporting(E_ALL | E_STRICT);
$emptyArray = array();
if (is_array($emptyArray[0]) === false) {
echo 'false returned';
}
?>
Output:
Notice: Undefined offset: 0 in test.php on line 5
false returned
----
Server IP: 203.169.204.174
Probable Submitter: 220.232.139.192
----
Manual Page -- http://www.php.net/manual/en/function.is-array.php
Edit -- https://master.php.net/note/edit/99429
Del: integrated -- https://master.php.net/note/delete/99429/integrated
Del: useless -- https://master.php.net/note/delete/99429/useless
Del: bad code -- https://master.php.net/note/delete/99429/bad+code
Del: spam -- https://master.php.net/note/delete/99429/spam
Del: non-english -- https://master.php.net/note/delete/99429/non-english
Del: in docs -- https://master.php.net/note/delete/99429/in+docs
Del: other reasons-- https://master.php.net/note/delete/99429
Reject -- https://master.php.net/note/reject/99429
Search -- https://master.php.net/manage/user-notes.php