>> English << | Português | По-русски | ZVON > Tutorials > CSS tutorial |
Intro / Search / ZVON |
>> Example 5 << | Prev | Next | Contents |
If several elements share the same property, this property can be specified in one place. In this case the definition in curly brackets is preceded by a list of selectors (element names) separated by commas.
>> Case 1 <<HTML Source | CSS stylesheet |
---|---|
<h2> h2-h2-h2 </h2> <h3> h3-h3-h3 </h3> <div> div-div-div </div> <div> <b> b-b-b-b </b> </div> <div> <em> em-em-em </em> </div> <div> <strong> strong </strong> </div> | body {background-color: white;
color: black} h2, h3 {background-color: black; color: white} b, em, strong {color: green; } |