dealmaker
12-31-2005, 05:45 AM
Hi,
Can I do the following? It doesn't have definition of the child class.
class child extend parent;
Many thanks.
dumpfi
12-31-2005, 12:11 PM
Instead of asking, you could've simply tried it. But no, you cannot do it that way. However, you can do this:
class child extends parent {}Oh, and use "extends" instead of "extend", because PHP doesn't like it, if you use undefined keywords.
dumpfi
Kurashu
12-31-2005, 07:57 PM
Here is the PHP Documentation on Classes and Objects, it'll answer a lot of questions for you.
PHP 4 (http://www.php.net/manual/en/language.oop.php)
PHP 5 (http://www.php.net/manual/en/language.oop5.php)