Tuesday, 20 March 2012

MULTI DIMESIONAL ARRAY

<html>
<head>
<title>****  multidimensional array  ****</title>
</head>
<body>

<?php
$families = array
(
  "Griffin"=>array
  (
  "Peter",
  "Lois",
  "Megan"
  ),
  "Quagmire"=>array
  (
  "Glenn"
  ),
  "Brown"=>array
  (
  "Cleveland",
  "Loretta",
  "Junior"
  )
);

echo "Is " . $families['Griffin'][2] . 
" a part of the Griffin family?";
?>
 
OUTPUT
Is Megan a part of the Griffin family?

 





No comments:

Post a Comment