Freddy Andersen wrote: > In Rails if the form field is empty it will submit an empty params > value.. Thats how it works by default. > > Maybe an example would be better? > > > If you had two inputs, i1 and i2 and i1 had the word here and i2 was > empty when you press submit you get this back to you controller: > > i1="here" i2="" > > and if there is no validation rules in the model that would be saved > with the blank field.. > > Sounds like you are thinking Java and not Rails... > > On Jan 30, 2:49�pm, Taylor Strait <[email protected]>
Thanks for the response. My form is not tied to a model and is generated dynamically. But I have my submission button redirect to a view that displays the params - many fields that are skipped are NOT submitted as params. I see now that is DOES submit empty text fields. But it does not submit empty radio button groups or checkboxes. I need tall form elements as params even if they aren't checked / selected / filled out. Since the forms are generated dynamically I cannot manually add empty fields on save. So I guess my refined question is: How do I force the submission of radio buttons / checkboxes if empty? -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

