Forum: Ruby on Rails 2nd Submit button with options

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Glenn C. (Guest)
on 2006-06-07 17:46
I wish to have 2 submit buttons one which does a normal sumbit and the
other that does a submit but also passes the parameters such as
"render_action" .


This doesnt work
<%= start_form_tag :action => 'list' %>
<%= image_submit_tag("find.gif", :alt => "Find and Display", :border =>
0) %>
<%= link_to image_tag("excel.gif", :alt => "Find and Download to Excel",
:border => 0),  {:action => 'list' , :render_action => 'excel', :popup
=> true }%>

Include deleted <%= check_box_tag ("include_deleted", value="1" )

<%= end_form_tag %>

The reason is that the user can enter some checkbox infomation such as
"include deleted" . So when the user hits the excel link the list
controller is called but the include_deleted check box is lost.

Sorry I cannot think of a solution. I know it must be reasonably simple
This topic is locked and can not be replied to.