note 16638 modified in keyword.extends by danbrown
| From: | danbrown@php.net | Date: | Wed, 17 Jun 2009 19:11:13 +0000 |
| Subject: | note 16638 modified in keyword.extends by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-157040@lists.php.net to get a copy of this message | ||
Just one thing that may seem obvious but not mentionned in this page is that you need to
include/require the file containing the parent class or else you'll get an error:
<?php
require(dirname(__FILE__).'/'.'myParent.php');
// ...
myChild extends myParent {
// ...
}
// ...
?>
--was--
Just one thing that may seem obvious but not mentionned in this page is that you need to
include/require the file containing the parent class or else you'll get an error:
<?php
require(dirname(__FILE__).'/'.'myParent.php');
...
myChild extends myParent {
...
}
...
?>
http://php.net/manual/en/keyword.extends.php