CSS (Cascading Style Sheet) is a proposal issued and maintained by W3C. Its version has three types: CSS1, CSS2, and CSS3. It is not only the protagonist of front-end web page layout and presentation, but also an important tool for positioning target data when writing web crawlers. The selector syntax is organized as follows, and detailed test examples refer to:
- CSS Level 1 selector (released in 1996):
2. CSS Level 2 selector (released in 1998):
CSS2 is a superset of CSS1 (superset, that is, CSS2 contains CSS1 syntax). The new features mainly provide absolute, relative, fixed address syntax and z-index of elements.
3. CSS Level 3 selector (released in 1999):