阅读背景:

Rails:将所有未知的路由重定向到root_url

来源:互联网 

Whenever a user hits the wrong page, rails shows 404.html from the public folder. However, I'd like just to redirect the browser to the root page, without showing anything. So I tried globbing, but came to no avail, it still shows the 404 page. Here's an extract from my routes file:Whenever a user hits the wrong page, rails show




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: