This is what I have in my view:
<%= form_tag(request.url, :method => 'get') do %>
<%= select_tag(:filter, options_for_select([['all', 'all'], ['Active & Planned', 'active_planned'], ['Archived', 'archived']])) %>
<% end %>
I can access the selected “filter” using params[:filter]. How can I show the one that was selected when the form was submitted? Right now it always goes back to the first option, all
Change your code as below
This will select the option value which is equal to params[:filter]