Chapter 53. Highlighting Text with Color

In Topic 5, you saw how to set the default text color of a Web page along with the default background color and link colors. This topic looks at how to change the color of specific text elements or pieces of text within an element without affecting the default text color.

If you're one of those diehard Web designers who insist on using the font tag, you'll be happy to know that the color property of this tag does the job:

<font face="Arial, Helvetica, sans-serif" color="#FF0000">
  <h3>Note</h3>
  <p>You <strong>must</strong> supply your current email address.</p>
</font>

Just as the typeface of the font tag applies to all the text elements nested inside it, the font color also applies. In the preceding ...

Get Web Design Garage now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.