Posted by Marcel on 12/07/05 10:51
I am running PHP version 4.3.11-dev:
The class as defined below does not work:
<?php
class hello {
public function printHello() {
echo "HELLO";
}
}
$obj = new hello;
$obj->printHello(); // does NOT print hello
?>
When i delete the 'public' keyword then the above works ok!
Is it maybe because 4.3.11-dev probably does not fully support classes?
Marcel
Navigation:
[Reply to this message]
|