开发者

Auth redirects to SController

I have a few controllers, for example 'blogs' and 'users', if I go to 'blogs/add' I get redirected to the auth login page, when I login I should get back to 'blogs/add', but I get redirected to 's/add' instead!

This doesn't happen when I try the same thing but with the u开发者_Go百科sers controller or with any other controller.

As far as I can see there are no strange functions in the blogs controller, I just baked it with 'cake bake controller blogs scaffold' and didn't change anything.


Have you defined any custom routes? ( in /app/config/routes.php )


I found the answer, my project was named "blog" and apparently you can't name your project the same as your controller ("blogs"). It's an bug in the Auth component wich doesn't redirect right, you can just rename your project to solve it.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜