note 7827 added to array_keys

From: Date: Wed, 16 Aug 2000 14:28:14 +0000
Subject: note 7827 added to array_keys
Groups: php.notes 
Request: Send a blank email to php-notes+get-1957@lists.php.net to get a copy of this message
I couldn't get scott@cyberwars.com example to work, so here I modified it slightly: function array_keys ($x) { if (is_array($x)) { $i=0; while ($i<count($x)) { $y=each($x); $z[$i]=$y[0]; $i=$i+1; } return $z; } else { return FALSE; } } http://www.php.net/manual/function.array-keys.php

« previous php.notes (#1957) next »