Ok basically I have a search form to search for profiles given certain parameters. Here's what I have for part of it <div id="address_item" class="left"> <%= f.label :gender %><br /> <%= f.select :gender, Profile::GENDERS, :prompt => 'All' %> </div> <div id="address_item" class="left"> <%= f.label :age %><br /> <%= f.select :age, Profile::AGES, :prompt => 'All' %> </div> Now the gender field defaults to 'All' when you load the page just like the :prompt says, but for some reason the age field doesn't contain 'All' and defaults to the first value in the array. I can't figure out why it's doing this. Both fields are exactly the same, but the age field doesn't have 'All' as an option from the :prompt. I have a degree field that is also the same and works properly. The problem seems to occur within the f.select :age. If i change it to f.select :something_else it works fine. Is there some kind of problem with naming a field age maybe? Thanks for any help because I'm stumped on this one.
on 2008-10-06 19:16
on 2008-10-06 19:59
Actually disregard that, I figured out why it was doing that. Had nothing to do with the age field.