array_keys

It returns all the keys or a subset of the keys of an array

Example

<?php
echo “<pre>”;
$array = array(PHP => 11, “ASP” => “22”);
print_r(array_keys($array));
?>

Output

Array
(
[0] => PHP
[1] => ASP
)