Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

php all keys in array

<?php
$array = array(
    'fruit1' => 'apple',
    'fruit2' => 'orange',
    'fruit3' => 'grape',
    'fruit4' => 'apple',
    'fruit5' => 'apple');

$keys = array_keys($array);		// return array
$values = array_values($array);	// return array
?>
 
PREVIOUS NEXT
Tagged: #php #keys #array
ADD COMMENT
Topic
Name
8+1 =