Skip to main content
added 133 characters in body
Source Link
Marc Audet
  • 47k
  • 11
  • 68
  • 86

As suggested by thgaskell, here is one way of doing it:

#navigation li a { color: green; line-height: 22px; font-size: 11px; text-decoration: none; padding: 5px 15px 6px 15px; border-right: 1px solid red; } #navigation li:last-child a { border-right: none; } 

Demo at: http://jsfiddle.net/audetwebdesign/G3mD9/

Note: the last-child pseudo-class is supported for IE9+, so a bit more limited than first-child which is good for IE7+.

As suggested by thgaskell, here is one way of doing it:

#navigation li a { color: green; line-height: 22px; font-size: 11px; text-decoration: none; padding: 5px 15px 6px 15px; border-right: 1px solid red; } #navigation li:last-child a { border-right: none; } 

Demo at: http://jsfiddle.net/audetwebdesign/G3mD9/

As suggested by thgaskell, here is one way of doing it:

#navigation li a { color: green; line-height: 22px; font-size: 11px; text-decoration: none; padding: 5px 15px 6px 15px; border-right: 1px solid red; } #navigation li:last-child a { border-right: none; } 

Demo at: http://jsfiddle.net/audetwebdesign/G3mD9/

Note: the last-child pseudo-class is supported for IE9+, so a bit more limited than first-child which is good for IE7+.

Source Link
Marc Audet
  • 47k
  • 11
  • 68
  • 86

As suggested by thgaskell, here is one way of doing it:

#navigation li a { color: green; line-height: 22px; font-size: 11px; text-decoration: none; padding: 5px 15px 6px 15px; border-right: 1px solid red; } #navigation li:last-child a { border-right: none; } 

Demo at: http://jsfiddle.net/audetwebdesign/G3mD9/