Removing Font Elements


Instead of using <font> elements throughout a document, you should use CSS to style the content. This reduces the overall file size and makes future maintenance easier. All font-styling information can be stored in one external file, rather than scattered throughout every document in a website.

The <font> elements will be removed from the HTML markup as shown in Listing 7.2. The first paragraph will be styled with an introduction class because it will need additional styling (see Figure 7.2).

Listing 7.2. HTML Code Containing the Markup Without <font> Elements
<p >     Lorem ipsum dolor sit amet, consectetuer adipiscing     elit... </p> <p>     Ut wisi enim ad minim veniam, quis nostrud exerci... </p> <p>     Duis autem vel eum iriure dolor in hendrerit vulputate... </p>     Ut wisi enim ad minim veniam, quis nostrud exerci... </p> 

Figure 7.2. Screenshot of paragraphs with <font> elements removed.





Sams Teach Yourself CSS in 10 Minutes
Sams Teach Yourself CSS in 10 Minutes
ISBN: 0672327457
EAN: 2147483647
Year: 2005
Pages: 234
Authors: Russ Weakley

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net