If not text_field, then what?

I want the show.rhtml to generate a drop down list (I’ll deal with
populating that list later). What’s the syntax please to generate a
drop-
down list?

All code at: http://strawr.googlecode.com/svn/

Here’s what I have:

[email protected] ~/Desktop $
[email protected] ~/Desktop $ tail strawr/app/views/feeds/show.rhtml

<%= start_form_tag :action => ‘record’, :id => @category %>

<%= text_field 'category', 'category'%>

<%= submit_tag 'Record!' %> <%= end_form_tag %>

[email protected] ~/Desktop $

thanks,

Thufir

Quoting T. [email protected]:

I want the show.rhtml to generate a drop down list (I’ll deal with
populating that list later). What’s the syntax please to generate a drop-
down list?

See the select helpers. http://rails.rubyonrails.com/ has nice
documentation.

HTH,
Jeffrey

On Tue, 25 Dec 2007 15:44:18 -0600, Jeffrey T. wrote:

See the select helpers. http://rails.rubyonrails.com/ has nice
documentation.

Thanks, it certainly gets me started. I have an empty list and am now
working on a query of the “categories” table to populate the list with
all the categories:

[email protected] ~/Desktop/strawr $
[email protected] ~/Desktop/strawr $ tail app/views/feeds/show.rhtml -n 2

[email protected] ~/Desktop/strawr $

http://strawr.googlecode.com/svn/trunk/app/views/feeds/show.rhtml

thanks,

Thufir

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs