0

I use views_slideshow and I use it's option Items Per Slide and I set it to 2, so it shows two nodes at a time. Problem is now, I cannot give both nodes separate styling, i.e. I want first row to have padding to right and second row to have padding to left, I could do that if it didn't have identical row-number classes:

enter image description here

0

You could easily achieve what you need with a small workaround using css pseudo classes :first-child and :last-child, apply them to the surrounding div and easily get the paddings for first and last elements. See this and this.

  • Does this support IE8? – Optimus Prime Mar 1 '14 at 12:55
  • First-child yes, last-child no. But in your case since there are 2 elements only, you can do padding on all rows an then override it for the first one. – m1n0 Mar 1 '14 at 13:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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