Here's my php code
$values = array(
'php' => 'php hypertext processor',
'other' => array(
'html' => 'hyper text markup language',
'css' => 'cascading style sheet',
'asp' => 'active server pages',
)
);
function show($id='php', $id2='others') {
global $values;
if(isset($id2)) {
$title = $values[$id];
}
elseif(empty($id2)) {
$title = $values[$id][$id2];
}
return $title;
}
when i do
echo show('php');
it shows "php hypertext processor"
but when i do
echo show('other','asp');
it doesnt work properly, it should display "active server pages"
Whats the error i am making? Can anybody help me out?