I have a form below displayed on /parties and would like to take whatever a user inputs in this form and add it to the url. I.e. if they searched for “hello” they would be redirected to parties/hello
<h1>Search for a Party</h1><br>
<%= form_tag({:action => "search"}, {:method => "get"}) do %>
<%= label_tag :q, "Enter Playlist Code:" %>
<%= text_field_tag(:q) %>
<%= submit_tag("Find Playlist", :name => "submit") %>
<% end %>
What is the best way to do this?
The logic would go into the PartyController.
Something like this in (syntax may be a little off):
PartyController.rb