On Apr 16, 11:58 pm, Phil Crissman <phil.criss...@gmail.com> wrote:
> Phil
>
I tried this and it isn't working out.
I have a job model. In the views/jobs/index.html.erb file I have the
following at the top.
<h1>Listing jobs</h1>
<%= form_tag search_jobs_path, :method => :get do %>
<p>
  <%= text_field_tag :query, params[:query] %> <%= submit_tag
"Search!" %>
</p>
<% end %>

When i put in the route as below and try to pull up the jobs index, I
now get a compile error. It does not like this line:
<%= form_tag search_jobs_path, :method => :get do %>

So what am I missing here?

>
> map.resources :jobs, :collection => {:search => :get}
>
> You can also still find the rails 2.3.x rails guides, which includes the
> routing guide, from the index page ofhttp://guides.rubyonrails.org/
>
>
>
>
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Ruby on Rails: Talk" group.
> > To post to this group, send email to rubyonrails-talk@googlegroups.com.
> > To unsubscribe from this group, send email to
> > rubyonrails-talk+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> >http://groups.google.com/group/rubyonrails-talk?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to