In PhpStorm class methods and class properties may not be found when you open a file that does not belong to the current project.|
Method '***' not found in ****
Inspection info: Referenced method is not found in subject class.
Field '***' not found in ****
Inspection info: Referenced field is not found in subject class.
Note: Check is not performed on objects of type "stdClass" or derived.
- Go to File -> Settings -> Directories -> Add Content Root in PHPStorm
- Add the path of the containing folder of the file that comes up with these error messages to the list
- Hit the OK button.