I am using cakephp 3. I want to hide frontends controller in url.
My Routes config:
Router::connect('/:action', array('controller' => 'frontends'));
And I want to refer all function to bloggers controller when url start as www.example.com/bloggers
Router::connect('/bloggers/:action', array('controller' => 'bloggers'));
But www.example.com/bloggers also refers to frontends Controller's index function. It should refer to bloggers Controller's index function. Any help?
Just change the order of your routing
First write this
and then this one