Two-Dimensional Arrays In PHP
[ Thanks to Tre Harmon for this link. ] This Scriptlet goes over a nice way of creating and returning a 2 dimensional array in PHP.
This Scriptlet goes over a nice way of creating and returning a 2 dimensional array in PHP...
Excerpt:
/*
Scenario:
You need to store info for 3 people and for each person you must have their:
Age, Gender, and Job Title.
*/
// Create 2 Dimensional Array.
= array(
"Bill" => array("21","Male","Customer Service Rep"),
"Lisa" => array("22","Female","Intranet Site Admin"),
"Tre" => array("23","Male","Mailroom Geek")
);
Scriptlet Url:
http://php.lansystems.com/index.php?archive=2d_arrays.inc
Page
1 of
1
0 Comments (click to add your comment)

