Search code examples
yii2yii-url-manageryii2-basic-app

Yii2 access to actions in new controllers


Comrades, I have had issues implementing yii2 basic but I'm yet to give up. I have successfully installed yii2, activated pretty url and created the .htaccess file in the root folder. The Home, About, Contact and Login urlswork fine.

i. I have created a new model, InstTypes with the CRUD. Why does http://localhost:8081/we@ss/instTypes/create return Not Found (#404)?

ii. I have also created a module instClients. I can access the index action in the DefaultControler. I have a model Insts with its CRUD under this modules. Why does http://localhost:8081/we@ss/instClients/insts/create return Not Found (#404)?

I tend to think that this could be due to the removal of the import and autoload from the config.

Could someone demonstrate how they've created a new model and CRUD and successfully accessed its actions?

Thanks in advance


Solution

  • this solved my problem. I needed to add the controllers to the controller map.