CSS Adjacent Sibling Selector
Structure
element1 + element2
Description
This selector allows us to select an element which follows after its sibling-element in the document (p and p are siblings, ul and ol are siblings, h1 and h2 are siblings...). Plain text is ignored (elements aren't ignored). Only elements and their position in the markup structure matter.
Examples
Compatibility
Chrome | Firefox | Internet Explorer | Opera | Safari |
---|---|---|---|---|
2.0+ | 1.0+ | 7.0+ (7 is buggy) | 9.2+ (9.2 is buggy) | 1.3+ (1.3 to 4.0 are buggy) |