Forum: Ruby on Rails why can't I add a :class to text_field?

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Zhenning G. (Guest)
on 2009-06-08 09:57
<%= text_field_tag 'login' ,nil, {:class => 'line'} %>
 the old way work.

<%= f.text_field :login, :class => 'line' %>
 but why this doesn't.
Mukund (Guest)
on 2009-06-08 11:36
(Received via mailing list)
What is 'f' ?  form_tag or field_tag for which object?

On Jun 8, 10:57 am, Zhenning G. <removed_email_address@domain.invalid>
This topic is locked and can not be replied to.