I want to set up pagination in CakePHP 2.0. The base page url is routed to be like this - '/mypage'.However, the paginator sets links to this - '/controller/mypage/page:2'. How do I configure this so the controller name isn't added in the beginning? I prefer URLs like these - '/mypage/page:2' or even '/mypage/2'. The router is set to route '/mypage' and '/mypage/:page' URLs. Any help would be good.


It is not possible to remove the controller name from url as without controller Cake can't read the paginator. Though you can use the IndexController to make this done.