note 66760 added to function.current

From: Date: Sun, 28 May 2006 09:55:42 +0000
Subject: note 66760 added to function.current
Groups: php.notes 
Request: Send a blank email to php-notes+get-112431@lists.php.net to get a copy of this message
May be worth noting that if the array you are using with current() is a reference, you will need to pass a reference to current() as well. For example: <?php $test_array = array('a', 'b', 'c'); $loop_array =& $test_array; while ($current = current(&$loop_array)) { // Do stuff } ?> ---- Server IP: 84.18.202.180 Probable Submitter: 212.56.109.105 ---- X-Spam-Status: No, hits=3.1 required=5.0 tests=DATE_MISSING,FROM_NO_LOWER autolearn=no version=2.64 ---- Manual Page -- http://www.php.net/manual/en/function.current.php Edit -- http://master.php.net/note/edit/66760 Del: integrated -- http://master.php.net/note/delete/66760/integrated Del: useless -- http://master.php.net/note/delete/66760/useless Del: bad code -- http://master.php.net/note/delete/66760/bad+code Del: spam -- http://master.php.net/note/delete/66760/spam Del: non-english -- http://master.php.net/note/delete/66760/non-english Del: in docs -- http://master.php.net/note/delete/66760/in+docs Del: other reasons-- http://master.php.net/note/delete/66760 Reject -- http://master.php.net/note/reject/66760 Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#112431) next »