码农教程
: php数据类型对象实例
编辑代码
执行
color = $color; } function what_color() { return $this->color; } } $test= new Car(); $test->Car("blue"); echo $test->what_color(); ?>
结果: