note 18825 added to function.each

From: Date: Wed, 06 Feb 2002 20:59:10 +0000
Subject: note 18825 added to function.each
Groups: php.notes 
Request: Send a blank email to php-notes+get-26311@lists.php.net to get a copy of this message
Due to the way each works, if you want to use each on a serialized array, you have to unserialize it first into a temp var eg: $a=unserialize($sarray); while (list($job, $grades) = each($a)) works, but while (list($job, $grades) = each(unserialize($sarray))) { doesnt! -- http://www.php.net/manual/en/function.each.php http://master.php.net/manage/user-notes.php?action=edit+18825 http://master.php.net/manage/user-notes.php?action=delete+18825 http://master.php.net/manage/user-notes.php?action=reject+18825

« previous php.notes (#26311) next »