note 80179 added to control-structures.foreach
| From: | dennismv at hotmail dot com | Date: | Thu, 03 Jan 2008 00:45:15 +0000 |
| Subject: | note 80179 added to control-structures.foreach | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-134672@lists.php.net to get a copy of this message | ||
Why not do
foreach ($user in $users)
foreach ($key => $user in $users)
I think this way is more intuitive than what you have now.
----
Server IP: 64.71.164.2
Probable Submitter: 69.208.37.171
----
Manual Page -- http://www.php.net/manual/en/control-structures.foreach.php
Edit -- https://master.php.net/note/edit/80179
Del: integrated -- https://master.php.net/note/delete/80179/integrated
Del: useless -- https://master.php.net/note/delete/80179/useless
Del: bad code -- https://master.php.net/note/delete/80179/bad+code
Del: spam -- https://master.php.net/note/delete/80179/spam
Del: non-english -- https://master.php.net/note/delete/80179/non-english
Del: in docs -- https://master.php.net/note/delete/80179/in+docs
Del: other reasons-- https://master.php.net/note/delete/80179
Reject -- https://master.php.net/note/reject/80179
Search -- https://master.php.net/manage/user-notes.php