Man-wai Chang wrote:
> myarray=array()
> myarray['a']=1
> myarray['b']=1
> myarray['c']=1
>
> Is there an iterative way to find out the array index values ('a', 'b'
> and 'c') of myarray?
>
>
array *array_keys* ( array $input [, mixed $search_value [, bool $strict]] )
*array_keys()* returns th
foreach ($myarray as $key => $value)
{
echo "$key = $value";
}
> -Original Message-
> From: news [mailto:[EMAIL PROTECTED] On Behalf Of Man-wai Chang
> Sent: Sunday, April 01, 2007 3:59 AM
> To: php-general@lists.php.net
> Subject: [PHP] finding the index
myarray=array()
myarray['a']=1
myarray['b']=1
myarray['c']=1
Is there an iterative way to find out the array index values ('a', 'b'
and 'c') of myarray?
--
.~. Might, Courage, Vision, SINCERITY. http://www.linux-sxs.org
/ v \ Simplicity is Beauty! May the Force and Farce be with you!
/( _
3 matches
Mail list logo