I am trying to create a log-in page where the person logs in and based
on where or not they entered the correct format for a password and email
address, they may proceed to the next page. If, however, the check
fails, they get kicked back to the log-in page. What I would like is to
have the info (excluding their password and emailaddress which is what
would make the log-in fail), be re-displayed in the form when they get
kicked back. I have tried:
in my controller which I was hoping would just kick back the params
hash, but it doesn’t work. Any ideas, thanks in advance, and thank God
it’s Friday!
<dirty_mode>
before you redirect set a variable @login = params[:user_name] for
example
in your view you put as option in your text_field ‘:value => @login’
</dirty_mode>
<dirty_mode>
before you redirect set a variable @login = params[:user_name] for
example
in your view you put as option in your text_field ‘:value => @login’
</dirty_mode>
<dirty_mode>
before you redirect set a variable @login = params[:user_name] for
example
in your view you put as option in your text_field ‘:value => @login’
</dirty_mode>
it never shows the value attribute in the raw html. Is :value one of the
ptions that you can pass to the text_field helper?
Yes it does.
problem is maybe that in your ‘traveler_form’ action, you 'll override
this value.
Are you doing maybe @user = User.new there ?
That’s one of the reasons why it would be better not to do a redirect,
but only a :render.
Stijn
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.