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

application as folder in webroot

I've placed my applications as folder in a webroot. for example :

https://site.com/myapp1 https://site.com/myapp2

in phalcon 3.x i have no problem at all. but since i use phalcon 4.x. it always shows controller not found. as it appears myapp1 is considered as controller.

i've set the router : $router->handle($_SERVER["REQUEST_URI"]);

any help is appreciated thanks



448
Accepted
answer

i've found solution :

change

$router->handle($_SERVER["REQUEST_URI"]);

to

$router->handle($_GET['_url'] ?? '/');