Forum: Ruby on Rails losing validation error messages

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Cagan (Guest)
on 2006-05-15 19:54
(Received via mailing list)
Hello all,
I am pretty new to Rails and have recently started on a simple
project with it..
I have a simple home_controller and home/index.rhtml page that
displays a login/registration form.
The login/registration actions are handled by users_controller.rb.

register action in users_controller always redirects back
to :controller => "home", :action => "index"..

The whole site uses one layout: application.rhtml.

The problem is if there is an error in registration process, for
example a validation error, the errors are not displayed in the home/
index.rhtml. My guess is during the redirect, the error messages get
lost as they are not flashed..

Two questions: am I doing this correctly (meaning having
user_controller redirect to home controller) and second how can I get
the error messages to display properly?

This topic is locked and can not be replied to.