note 77890 deleted from function.list by googleguy
| From: | googleguy@php.net | Date: | Thu, 13 Sep 2012 10:05:16 +0000 |
| Subject: | note 77890 deleted from function.list by googleguy | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-190701@lists.php.net to get a copy of this message | ||
Note Submitter: tenz699 at hotmail dot com
----
PhP manual's NOTE says: list() only works on numerical arrays and assumes the numerical indices
start at 0.
I'm finding it do works for associative arrays too,as below:
<?
$tenzin = array ("1" => "one", "2" =>
"two","3"=>"three");
while(list($keys,$values) = each($tenzin))
echo($keys." ".$values."<br>");
?>
gives O/P
1 one
2 two
3 three
tsarma