Previously used yii2 basic , and no problems!

But now you need to use advanced , but with a problem!

For some reason, an error occurs with the namespace , the system simply does not see them!

example index.php in frontend:

enter image description here

How can I fix this?

    1 answer 1

    Just phpStorm does not see the contents of the vendor folder. If you are editing files on ftp, then download them again.

    • in order to upload vendors to the server, it is enough to do a php composer install via the console, by ftp this is long and unproductive :) - MasterAlex
    • You did not understand me. You installed it on the server through the compositor, of course. But if you edit your application via FTP, then you need to suck in your car not only the application, but also the vendor. Not on the server, but on the computer itself. - zabachok
    • By the way, yes, on the computer in the right folder run in the console php composer install , so that the system saw :) - MasterAlex