Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Using nth child with odd row of items

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #237734
    Ricky55
    Participant

    Hi guys

    Is there a better or more efficient way of achieving this?

    I’m basically wanting to select the first item in each row to remove its margin, marked in teal in my example. I’ve got it working with a bit of a hack but this content will be dynamic so it won’t really work long time.

    I thought using nth child 7 would work but because of the odd number of items it doesn’t. Well I think thats why.

    Take a look at my pen http://codepen.io/qwerty-design/pen/JGmYwo

    Any tips most appreciated.

    Thanks

    Richard

    #237738
    cwc
    Participant
    #237742
    Ricky55
    Participant

    Thanks man you’ve cracked it! Deadline looming and I wanted something more robust than the hack I was using.

    Thanks again very much appreciated!

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘CSS’ is closed to new topics and replies.