HomeMenu
Jesus · Bible · HTML · CSS · JS · PHP · SVG · Applications

nth-last-child

Description

The nth-last-child pseudo-class for CSS represents elements that are among An+Bth elements from the list composed of their inclusive siblings that match the selector list S, counting backwards from the end.

If S is omitted, it defaults to *|*.

Syntax

selector:nth-last-child(An+B [of S]? )
{
    property: value;
}

Examples

1 · CSS · An+B

2 · CSS · of S

3 · CSS · even

4 · CSS · odd

5 · JS · An+B

6 · JS · of S

7 · JS · even

8 · JS · odd