Following the teacher step by step, why does the teacher’s final running result peter appear, but I did not report an error, but the browser does not display the word peter.
1232020-11-24 11:41:14
__construst () The constructor must be double underlined. Most magic methods are like this
小幸运?2020-11-24 11:40:25
Print $obj to see if the data is correct
// 1. Check whether the class exists
var_dump( class_exists('Staff') );// 2. Check whether the attribute exists
var_dump( property_exists('Staff', 'name') );// 3. Get all properties of 1 in the class
var_dump( get_class_vars('Staff') );// 4 . Get all attributes in the object
$a = new Staff;
var_dump( get_object_vars($a) );// 5. Get all methods in the class
var_dump( get_class_methods('Staff') );// 6. Get the class name of the object
var_dump( get_class($a) );