note 38378 added to ref.array
| From: | jw at jwscripts dot com | Date: | Thu, 18 Dec 2003 17:41:15 +0000 |
| Subject: | note 38378 added to ref.array | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-62182@lists.php.net to get a copy of this message | ||
Not very useful, but nice to know is that you can also use casting to create arrays:
<?
$array = (array) null; // Empty array
$array = (array) 1; // Array with the first element set to 1
?>
----
Manual Page -- http://www.php.net/manual/en/ref.array.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+38378
Delete -- http://master.php.net/manage/user-notes.php?action=delete+38378&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+38378&report=yes
Search -- http://master.php.net/manage/user-notes.php