I'm writing a ruby on rails application, and am getting a compile error for the following code
<%= form_tag(search_path, :method => "get") do %>
<%= label_tag(:q, "Search for:") %>
<%= text_field_tag(:q) %>
<%= submit_tag("Search") %>
<% end %>
this is sample code from the ruby on rails forms guide: http://guides.rubyonrails.org/form_helpers.html
The error generated is,
compile error /Users/kmb89144/Desktop/Stoastic/app/views/application/index.html.erb:3: syntax error, unexpected ')' ...h_path, :method => "get") do ).to_s); @output_buffer.concat ... ^ /Users/kmb89144/Desktop/Stoastic/app/views/application/index.html.erb:13: syntax error, unexpected kENSURE, expecting ')' /Users/kmb89144/Desktop/Stoastic/app/views/application/index.html.erb:15: syntax error, unexpected kEND, expecting ')'
Extracted source (around line #3):
1:
2:
3: <%= form_tag(search_path, :method => "get") do %>
4: <%= label_tag(:q, "Search for:") %>
5: <%= text_field_tag(:q) %>
6: <%= submit_tag("Search") %>
Any suggestions?
Thanks