Skip to content

Instantly share code, notes, and snippets.

@dmclark
Created November 14, 2010 23:57
Show Gist options
  • Select an option

  • Save dmclark/676241 to your computer and use it in GitHub Desktop.

Select an option

Save dmclark/676241 to your computer and use it in GitHub Desktop.
<%= form_for @route, :html => {:method => :get}, :url => route_path, :remote => true do |f| -%>
<div class="field" style="float:left; padding-right:1em">
<%= f.label :startpoint_id %><br />
<%= f.select :startpoint_id, options_from_collection_for_select(@venues, 'id', 'name'), { :include_blank => false }, { :size => 15 } %>
</div>
<div class="field">
<%= f.label :endpoint_id %><br />
<%= f.select :endpoint_id, options_from_collection_for_select(@venues, 'id', 'name'), { :include_blank => false }, { :size => 15 } %>
</div>
<div class="field">
<%= f.label :mode %><br />
<%= f.radio_button :mode, "walking", { :checked => true} %> <%= f.label "mode_walking", "Walking Directions" %>
<%= f.radio_button :mode, "pubtrans" %> <%= f.label "mode_pubtrans", "Via Public Transportation"%>
</div>
<div class="actions">
<%= f.submit "Get Directions", { :id => "route_show" } %>
<input type="reset" value="Reset" id="route_clear">
</div>
<% end %>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment