1.

How to get specific key value from array in php?

Answer»

To check key in the array, we can use array_key_exists().

$item=array("NAME"=>"UMESH","CLASS"=>"mca");
if (array_key_exists("name",$item))
{
   echo "Key is exists";
}
ELSE
{
   echo "Key does not exist!";
}

 

 



Discussion

No Comment Found