I need help with PHP arrays?

myscranton

New member
Hi. This is what I am trying to do, I have an array:

$cars = array("honda" => "blue", "ford" => "blue", "toyota" => "red");

How can I get the numbers of the "blue" cars?
I don't want to get the names, like "Honda" and "Ford", I want it to return $cars[0] and $cars[1].

Can someone explain to me how to do this? Thanks.
 
Back
Top