PHP 코드관련

다차원배열

땀모 2019. 3. 30. 22:25

배열과 연관배열을 조합하여 다차원 배열이 됩니다.


 

$member[]

$member[] = array("name"=>"철수", "age" =>20, "tall"=>170);

//또는

$member[0] = array("name"=>"철수","age"=>20, "tall"=>170);




$member[] = array("name"=>"철수","age"=>20, "tall"=>170);

echo $member[0]["name"];

echo "
";

echo $member[0]["age"];

echo "
";

echo $member[0]["tall"];

echo "
";