|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2000-01-09 00:07 UTC] rasmus at cvs dot php dot net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Dec 19 15:00:01 2025 UTC |
function test() { global $pageinfo, $themes, $pagetheme, $pagename; echo "preloop"; while (list($akey) = each($pageinfo)) { echo "inloop"; } echo "postloop"; } In the above example, $pageinfo and $themes are arrays of arrays while $pagetheme and $pagename are just strings. In the above case, calling the function for the first time gives us preloop, inloop (many times) and postloop, which is fine. However, calling it the second time right after the first, or a bit later, yields only preloop and postloop.