On May 3, 2014, at 10:43 AM, Colin Law wrote: > On 3 May 2014 15:06, Alfredo Barrero <[email protected]> wrote: >> When I type 'http://localhost:3000/undefinded' I get this page: >> >> Routing Error >> >> No route matches [GET] "/undefined" > > I *think* that is because you are running in development mode. I > think that if you run it in a production environment that > public/404.html will be displayed, but I must admit I am not sure > exactly how this works. Perhaps someone more knowledgeable will add > detail or correct me.
You are correct. The development mode shows the "developer-friendly" errors, and the production mode shows the opaque "user-friendly" errors from the static /public/[nnn].html files. Edit those directly to make them appear any way you like. Remember, they will be served from the / root of the server, so any paths to resources need to be relative from that point. Walter > > Colin > >> >> >> This is a route problem, it is trying to load that path. >> >> Thanks. >> >> Alfredo. >> >> El 03/05/2014, a las 14:51, Colin Law <[email protected]> escribió: >> >> On 3 May 2014 13:41, Alfredo Barrero <[email protected]> wrote: >> >> Ok sorry. What I need is to redirect the application in the case a bad >> request comes to my application. For example: >> http://localhost:3000/undefinded >> >> The application have to redirect that request to a page that says something >> like "Sorry that page does not exist". >> >> >> That is already handled for you. Just edit public/404.html to say >> whatever you like. >> >> Colin >> >> -- >> You received this message because you are subscribed to a topic in the >> Google Groups "Ruby on Rails: Talk" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/rubyonrails-talk/ZIASaUTOaMg/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> [email protected]. >> To post to this group, send email to [email protected]. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/rubyonrails-talk/CAL%3D0gLspKRNEVWPQmCZpKg-rbO_BeMWwvCmecLtg-tvLGfBL%2BQ%40mail.gmail.com. >> >> For more options, visit https://groups.google.com/d/optout. >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Ruby on Rails: Talk" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> To post to this group, send email to [email protected]. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/rubyonrails-talk/5490C204-493D-42D8-BFF2-6CE6C7D1CC9B%40gmail.com. >> >> For more options, visit https://groups.google.com/d/optout. > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/rubyonrails-talk/CAL%3D0gLtZ4FuE0HJvHG%3DNsEL0r7EKGt8gU4t5ZAWXuEVQ%3D08r6A%40mail.gmail.com. > For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/BF928F06-2545-44AC-BC1E-2FE92B6E9EFC%40wdstudio.com. For more options, visit https://groups.google.com/d/optout.

