<?php
class AppConst{
const user=11;
public static $arr = [
'name'=>'张三',
'title'=>'测试',
];
}
$a = AppConst::user;
// var_dump($a);
$b = AppConst::$arr;
var_dump($b);
<?php
class AppConst{
const user=11;
public static $arr = [
'name'=>'张三',
'title'=>'测试',
];
}
$a = AppConst::user;
// var_dump($a);
$b = AppConst::$arr;
var_dump($b);
转载于:https://www.cnblogs.com/ayanboke/p/10071276.html