note 7824 deleted from function.sizeof by jimw

From: Date: Wed, 03 Apr 2002 18:58:35 +0000
Subject: note 7824 deleted from function.sizeof by jimw
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-28563@lists.php.net to get a copy of this message
To avoid such leaks (pressuming that you only want to pass through the array) and speeding up the code, you simply should use 'each'. 'for'-maniacs can use the following example too: for ($i=sizeof($arr);$i--;) { echo $arr[$i]; ...some sort of buggin code... } $i will be initialized only once! :-)

« previous php.notes (#28563) next »