PHP Code:
class System
{
protected $S_MYSQL_HOST;
protected $S_MYSQL_USER;
protected $S_MYSQL_PASSWORD;
protected $S_MYSQL_DB;
private $file;
protected function __construct($file)
{
$this -> file = //... usw.
}
}
class MySql extends System
{
public function __construct ($file)
{
parent::__construct ($file);
echo $this -> S_MYSQL_USER;
}
}
$myslq = new MySQL();
peter
EDIT:
außerdem solltest du dir mal autoload ansehen
Leave a comment: