output constructor variable value in oop php
My concept is very poor in o开发者_StackOverflow中文版op for php. My class has a constructor with three parameters.i create a object and pass three values to the constructor. Now, how will i show constructor value.
class Foo {
public function __constructor($para1, $para2, $para3 ){
echo $para1 . '<br>';
echo $para2 . '<br>';
echo $para3 . '<br>';
}
}
$f = Foo(10,20,30);
精彩评论