Testing reflection in PHP5, but has no luck.
<?php
class Foo {
public $prop;
function Func($name) {
echo "Hello $name";
}
}
reflection_clas s::export('Foo' );
reflection_obje ct::export(new Foo);
reflection_meth od::export('Foo ', 'func');
reflection_prop erty::export('F oo', 'prop');
reflection_exte nsion::export(' standard');
?>
It did not print anything.... Perhaps someone can tell me what I did wrong.
Thanks
<?php
class Foo {
public $prop;
function Func($name) {
echo "Hello $name";
}
}
reflection_clas s::export('Foo' );
reflection_obje ct::export(new Foo);
reflection_meth od::export('Foo ', 'func');
reflection_prop erty::export('F oo', 'prop');
reflection_exte nsion::export(' standard');
?>
It did not print anything.... Perhaps someone can tell me what I did wrong.
Thanks
Comment