为什么示例'mytest'不是数组?
class myclass {
public $mytest = array();
}
$insert = new myclass;
$insert -> mytest = Array (15, 50);
答案 0 :(得分:1)
这是一个数组:
class myclass {
public $mytest = array();
}
$insert = new myclass;
$insert -> mytest = Array (15, 50);
echo gettype($insert->mytest); // prints array