Forum: Ruby on Rails Adding an id to form_tag

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Schalk N. (Guest)
on 2008-10-15 15:57
(Received via mailing list)
Hi all,

When using form_for it is easy to add an id to the form using  :html =>
{:id => 'someid'}

However, how would one accomplish the same when using the form_tag ?

Thank you in advance,
Schalk
Frederick C. (Guest)
on 2008-10-15 16:18
(Received via mailing list)
On 15 Oct 2008, at 12:56, Schalk N. wrote:

>
> Hi all,
>
> When using form_for it is easy to add an id to the form using  :html
> =>
> {:id => 'someid'}
>
> However, how would one accomplish the same when using the form_tag ?
>
pretty much the same form_tag({ url options ... }, {:id => 'someid'})

Fred
Schalk N. (Guest)
on 2008-10-15 19:21
(Received via mailing list)
Thanks Frederick.
This topic is locked and can not be replied to.