Ruby on Rails
Saturday, June 27, 2015
Hello all,
-- I would like to have a form in which some of the fields are linked to model and some fields are not. When I use form_for tag it binds to a particular model and I cannot create form fields that aren't correspond to one of the column name of the table (Model). Hence what I think is I should use form_tag instead of form_for so that it contains whatever the form fields it want but one thing I can't find by googling is how can I connect specific fields to a model leaving other fields free of model?
In other words, If I have 5 text_fields in a form how can I link only 3 text_fields to a model and leave other 2 fields free?
Thank you.
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 rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/056c9834-ebd0-4b28-8191-623c933d7c3e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment