I creating a class for generating a html web page. I am now facing an error. I can't find where I have done wrong maybe I have typo can anyone help me? I would be appreciated. It is something that I didn't declare or anything I didn't add into it.
/*Singleton Design Pattern*/
class WEBPAGE{
private $title = "";
private $style = [];
/*Store Head, Body, Footer Content*/
private head = "";
private body = "";
private footer = "";
private function __constructor(){
$this->$title = "";
$this->$style = [];
}
private function styleGenerator($style){
$generated_style = [];
}
private function styleTag($src){
return '<link rel="stylesheet" href="'.$src.'">';
}
public static function getInstance()
{
if(!self::$instance)
{
self::$instance = new self();
}
return self::$instance;
}
public function ouput(){
//styleGenerator($this->$style);
echo "My blank page";
}
}
?>