Blogger Information
Blog 12
fans 0
comment 0
visits 6646
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
array数组第三课-php学习x+2课
虎哥的学习日志
Original
573 people have browsed it

数组中可以嵌套 各种类型的数据 数值型,字符型,数组,对象

$obj=new Classuser();

$obj->name='Jack';

$arr=[

'age'=>26,

'name'=>'Peter',

'edu'=>['html','css','php'],

'user'=>$obj,

];

print_r($arr);

print_r($arr['user']->name);

Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post