Excluding last-child
ul li:last-child selects the last element of a list.
ul li:not(...) selects an 开发者_如何学编程element that is not something
What is the CSS selector for excluding the last child of an element? I tried ul li:not(last-child) but it didn't work.
Did you try:
ul li:not(:last-child)
精彩评论