This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Although using $this keyword in non-object context causes fatal error in PHP, NetBeans PHP Editor allows to use it. It should be fixed
Please, more details, the best is an piece of php code with description, thanks
Here is my example code. Take a look at comments class exampleClass { function __construct() { echo 'hi!'; } public function exampleFunction() { return 'hi!'; } static function exampleStaticFunction() { // NetBeans allows to write following line in this method $text = $this->exampleFunction(); // Since exampleStaticFunction() is static a static function it cannot access object context. This code produces fatal error in apache. It should also give error in NetBeans } }
hmmm .. well, reporter is right, this could be underlined. Hint would be fine as well. I think it's enhancement not defect because it has never been implemented.
batch reassigning
Reproductible in 8.2rc / Dev 201609210002