note 75904 added to control-structures.foreach
| From: | SteveWard at osu1 dot php dot net | Date: | Thu, 21 Jun 2007 04:10:06 +0000 |
| Subject: | note 75904 added to control-structures.foreach | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-127847@lists.php.net to get a copy of this message | ||
@ kirk at proofed dot net
If you change the name of the value variable (i.e. $array) in the second foreach loop, the problem
goes away.
See explanation here:
"Looping through arrays with foreach"
http://groups.google.com/group/comp.lang.php/msg/bf35784c733ef439
----
Server IP: 64.71.164.2
Probable Submitter: 24.170.150.100
----
Manual Page -- http://www.php.net/manual/en/control-structures.foreach.php
Edit -- https://master.php.net/note/edit/75904
Del: integrated -- https://master.php.net/note/delete/75904/integrated
Del: useless -- https://master.php.net/note/delete/75904/useless
Del: bad code -- https://master.php.net/note/delete/75904/bad+code
Del: spam -- https://master.php.net/note/delete/75904/spam
Del: non-english -- https://master.php.net/note/delete/75904/non-english
Del: in docs -- https://master.php.net/note/delete/75904/in+docs
Del: other reasons-- https://master.php.net/note/delete/75904
Reject -- https://master.php.net/note/reject/75904
Search -- https://master.php.net/manage/user-notes.php