17 May 13:18
Select and how to read the api
From: Pål Bergström <rails-mailing-list@...>
Subject: Select and how to read the api
Newsgroups: gmane.comp.lang.ruby.rails
Date: 2008-05-17 11:21:42 GMT
Subject: Select and how to read the api
Newsgroups: gmane.comp.lang.ruby.rails
Date: 2008-05-17 11:21:42 GMT
I'm trying to understand how to use the select, especially how to make an option selected. I want to add the values manually, but be sure one value is selected when finding an existing post in the db. How are you supposed to understand how to do that from this? http://api.rubyonrails.org/classes/ActionView/Helpers/FormOptionsHelper.html#M000940 This is what I've used until now: <%= select 'user', 'age', ['','10-20','20-30','30-40','40-50','50-60','60-70','70+'] %> -- -- 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 rubyonrails-talk@... To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe@... For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
RSS Feed