[Previous] [Contents] [Next]

Classes


Class selectors can be used to define types of elements rather than named elements. A class selector is a string preceded by a period, and is called using the STYLE attribute.

.warning {color: red;}
     <H1 class="warning">WARNING!</H1>
     <P class="warning">Danger, Will Robinson!</P>

[Previous] [Contents] [Next]