Tuesday, October 19, 2010

Re: [Rails] form_tag not working correctly?

On 10-10-19 08:09 PM, Mohammad El-abid wrote:
> So I'm trying to make
> <form action='/path' method='get' class='ajax_box'>
>
> using:
>
> <% form_tag :action => "search_for", {:method => :get, :class =>
> 'ajax_box'} do %>
>
> but I get:
>
> <form action='/path?method=get&class='ajax_box' method='post'>
>
> Has form_tag changed with rails v3?
>

you can read about forms here:

http://guides.rubyonrails.org/form_helpers.html

one think i can point out, rails 3 use the equal sign now

<%= form_ ... %>

--
Kind Regards,
Rajinder Yadav | DevMentor.org | Do Good! ~ Share Freely

GNU/Linux: 2.6.35-22-generic
Kubuntu x86_64 10.10 | KDE 4.5.1
Ruby 1.9.2p0 | Rails 3.0.1

--
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+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate