CSS 2 Example 2

>> English << | česky | Português ZVON > Tutorials > CSS2 tutorial
Intro / Search / ZVON
>> Example 2 << | Prev | Next | Index | Contents

CSS2 offers many possibilities how to match an element. If only the element name is given, it matches everywhere (1). The character [*] matches any element (2).

XML SourceCSS stylesheetExample link
(1)
<AAA>
<BBB>bbb</BBB>
<CCC>ccc
<DDD>ddd</DDD>
</CCC>
</AAA>

BBB {color:red}
CCC {color:blue}
DDD {color:maroon}
View output
XML SourceCSS stylesheetExample link
(2)
<AAA>
<BBB>bbb</BBB>
<CCC>ccc
<DDD>ddd</DDD>
</CCC>
</AAA>

* {color:red}
View output

AltStyle によって変換されたページ (->オリジナル) /