PHP Two-dimensional array
$str = Array (
"Network Programming book" =>array (' a ', ' d ', ' er '),
"History book" =>array (' Boko ', ' fd ', ' Popo '),
"Literature book" =>array (' fd ', ' fd ', ' fd '),
);
echo $str [0][2];
Why not show
------Solution--------------------
Of course not show! No subscript 0, how to display?
------Solution--------------------
Because you were 0 of the place was replaced by ' network programming books '
echo $STR [' Network Programming book '][2]
------Solution--------------------
You this two-dimensional array, the outermost time the associative array subscript is the character channeling is not a number
------Solution--------------------
You can change the code to
$str = Array (
Array (' A ', ' d ', ' er '),//network programming Book
Array (' Boko ', ' fd ', ' Popo '),//history book
Array (' fd ', ' fd ', ' fd '),//literature book
);
echo $str [0][2];
This will show the