Displaying 1 result from an estimated 1 matches for "hotels_path".
2012 Apr 18
2
RoR - Search Forms with Checkboxes, display appropriate results
...? OR name LIKE ?'', "%#{params[:search]}%",
"%#{params[:search]}%")
arel = arel.where(''rating = ?'', params[:rating]) if
params[:rating].present?
(what to put here?)
arel
else
all
end
end
My index view:
<%= form_tag hotels_path, :method =>''get'' do%>
<p>
<b>Location:</b>
<%= text_field_tag :search, params[:search]%><br />
<b>Rating:</b><br />
<%= radio_button_tag :rating, ''5''...