We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

MVC\Simple-subcontrollers not working from scratch

Hello! Have a little problem.

I want to learn how to divide controllers in different folders. I see that "mvc\simple-subcontrollers" is suitable to my situation. But when I try to copy this from github (also trying to write it by myself) it only gives me error:

MyApp\Controllers\IndexController handler class cannot be loaded

Tried it on Windows environments (nginx + php-fpm) and also linux. Can anyone try to check this repo? Does it work?



85.5k
edited Apr '16

You need to load this class/namespace first in loader to use it.