Hello friends
I did a project using php 5.3, The project is working well in my machine, but when I put this project in other machine using php 5.6 to test I had this error:
Fatal error: Access to undeclared static property: Controller::$this in /Users/Alexandre/web_projects/empresa_nova/apps_administrator_php_yii/protected/controllers/SiteController.php on line 10
The error refer this line:
parent::$this->scriptJS = array(Yii::app()->request->baseUrl . "/libs/site/site.js");
This is the complete code:
public $scriptJS;
public $layout = "//layouts/default";
public function __construct($id) {
parent::$this->scriptJS = array(Yii::app()->request->baseUrl . "/libs/site/site.js");
parent::__construct($id);
}
Whats the problem?