This happens to me every few months with Phalcon and I forget about the problem and end up wasting so much time debugging it.
Let's say I have the following configuration.
- Not using modules
- A "controllers" and "views" directory
- Using the default Router
- Phalcon 3.0
Let's say I have two files in "controllers":
- IndexController.php
- TestController.php
Each of these both have two actions, let's say "indexAction" and "secondAction"
Now, If I visit the following url's:
- https://localhost/index/index
- https://localhost/index/second [This one doesn't work. It instead goes to
index/index
]- https://localhost/test/index
- https://localhost/test/second
Is there a known problem with having "index" as your handler (or controller) in which it is not able to access any of the actions of that controller?
Another interesting thing is that when I run my unit tests using $app->handle('index/second'), it does seem to hit the right action.