Forum: Ruby on Rails Syntax for <input type=hidden> in rhtml????

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.
Prashant T. (Guest)
on 2006-03-10 11:37
Hi,

I am new to ROR. PLease tell me what is syntax of creating hidden field
in form inside RHTML file. I knonw the syntax for text box (<%=
text_field 'product_item','product_id', :value=>product.id%>)
But I don't know syntax for hidden field(like <input type=hidden> in
HTML).

Please tell me.

Thanx in advance.
Prash
Chang Sau S. (Guest)
on 2006-03-10 11:48
(Received via mailing list)
Hi,

You should try to check up the rails api at http://api.rubyonrails.org/

anyway the syntax is *hidden_field*(object, method, options = {})


Prashant T. wrote:
> Thanx in advance.
> Prash
>
>


--
Sau S.

http://www.saush.com
http://read.saush.com
http://jaccal.sourceforge.net
Jonathan V. (Guest)
on 2006-03-10 12:12
(Received via mailing list)
Instead of text_field, use hidden_field. Simple!

-Jonathan.
This topic is locked and can not be replied to.