3

What is the recommended way to add a "clearfix" class to a div.views-row?

Note that I dont want to add the clearfix to all views, just a specific view.

Is this best done with a template override, or is there a mystical alter hook that will let me add in what I need in my template.php without having to override and thus maintain an entire views template file, just to add a class.

1 Answer 1

4

Is this views 3? If so if you go to the Settings for the format you can add a Row class (the description says "The class to provide on each row") which should do what you want without templates etc.

1
  • It is indeed Views 3, and this works perfectly! Thanks Malks, you learn something new (about views) everyday. Commented Dec 7, 2011 at 21:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.