retrieving values from combo box

<td><p align="right">Jul/10:</td>
  <td><%= select_tag "jul10",
"<option>Y</option><option>N</option><option>R</option>" %></td>

At the moment, my html form displays this combo box the way i want it,
but it does not record down what the user has selected and save it to
the database

help please,

thanks!

Are you generating your form using form_for :foo ?, if so then you’d want something like this:

<%= foo.select_tag :jul10, %w( Y N R ) %>

Assuming jul10 is a member of the object you’re saving into (using update_attributes, or new(params[:foobar])).

Does this help, if not, what does your controller method look like that is saving the record?

Cheers,
James

erm...i'm new to ruby =( don't really understand what you said, so
sorry

but i'm not generating my form, i created this <create> form myself
and replaced it in the _form.rhtml

<td><p align="right">Jul/10:</td>
  <td><%= select_tag "jul10",
"<option>Y</option><option>N</option><option>R</option>" %></td>

produces the combo box but doesn't actually save the value into my
database when the user clicks create, everything else that the user
types in other fields can be saved though.

below is the whole _form.rhtml

<p>
<%= error_messages_for 'course' %>
</div>

<!--[form:course]-->
<table cellpadding="2">
<tr>
  <td><h3>Course Details:<h3></td>
</tr>
...

<tr>
  <td><h3>Presentation Details:</h3></td>
</tr>

<tr>
  <td><p align="right">Final Presentation (mmm yyyy):</p></td>
  <td align="left"><%= text_field "course",
"final_presentation", :size=>"5" %></td>

  <td><p align="right">Presentation Pattern:</p></td>
  <td align="left"><%= text_field "course",
"presentation_pattern", :size=>"30" %></td>
</tr>

<tr>
  <td><p align="right">Jan/08:</td>
   <td><%= select_tag "jan08", "<option>Y</option><option>N</

<option>R</option>" %></td>

  <td><p align="right">Jul/08:</td>
    <td><%= select_tag "jul08", "<option>Y</option><option>N</

<option>R</option>" %></td>

</tr>

...
</table>
<!--[eoform:course]-->

thanks!