Tags


At times its required to make pretty . Forms can be created using form_for or form_tag

To add css class to form_for

  form_for @user, :html=>{:class=> "foo"}

To add css class to form_tag

  form_tag({:action => 'new',...}, {:class => 'my_form'}) do

Happy Coding !!

Advertisements