note 51224 deleted from language.types.array by betz
| From: | betz@php.net | Date: | Tue, 18 Oct 2005 06:18:16 +0000 |
| Subject: | note 51224 deleted from language.types.array by betz | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-97138@lists.php.net to get a copy of this message | ||
Note Submitter: keystorm at gmail
----
In reply to arhipov at donotspam at narod dot ru. This is not a strange behaviour, this is the
inbuilt string char index reference:
<?php
$string = 'Hello';
echo $string[1]; //This will print 'e' on screen
echo $string['random']; //This will return 'H' since the expected integer index
was not found and the string 'random' is int 0 (=> H)
?>