Check_box_tag css

Hi

How would I add a CSS class to a check_box_tag helper like this:

  check_box_tag("addable_photo[]", @photo.id)

Thanks!

Pieter M. wrote:

Hi

How would I add a CSS class to a check_box_tag helper like this:

 check_box_tag("addable_photo[]", @photo.id)

Thanks!

check_box_tag(“addable_photo[]”, @photo.id, flase, {:class =>
“someclass”})

The false indicates you don’t want the checkbox checked by default.
See: