Sams Teach Yourself HTML 4 in 24 Hours
- Table of Contents
- Copyright
- About the Author
- Acknowledgments
- Tell Us What You Think!
- Put Your HTML Page Online Today
- I. Your First Web Page
- Hour 1. Understanding HTML and XML
- Hour 2. Create a Web Page Right Now
- Hour 3. Linking to Other Web Pages
- Hour 4. Publishing Your HTML Pages
- II. Web Page Text
- Hour 5. Text Alignment and Lists
- Hour 6. Text Formatting and Font Control
- Hour 7. Email Links and Links Within a Page
- Hour 8. Creating HTML Forms
- III. Web Page Graphics
- Hour 9. Creating Your Own Web Page Graphics
- Hour 10. Putting Graphics on a Web Page
- Hour 11. Custom Backgrounds and Colors
- Hour 12. Creating Animated Graphics
- IV. Web Page Design
- Hour 13. Page Design and Layout
- Hour 14. Graphical Links and Imagemaps
- Hour 15. Advanced Layout with Tables
- Hour 16. Using Style Sheets
- V. Dynamic Web Pages
- Hour 17. Embedding Multimedia in Web Pages
- Hour 18. Interactive Pages with Applets and ActiveX
- Hour 19. Web Page Scripting for Non-Programmers
- Hour 20. Setting Pages in Motion with Dynamic HTML
- VI. Building a Web Site
- Hour 21. Multipage Layout with Frames
- Hour 22. Organizing and Managing a Web Site
- Hour 23. Helping People Find Your Web Pages
- Hour 24. Planning for the Future of HTML
- VII. Appendixes
- A. Readers' Most Frequently Asked Questions
- B. HTML Learning Resources on the Internet
- C. Complete HTML 4 Quick Reference
- D. HTML Character Entities
Font Size and Color
The <big>, <small>, and <tt> tags give you some rudimentary control over the size and appearance of the text on your pages. Generally, you should try sticking to those tags until you are ready for the advanced font formatting controls discussed in Hour 16.
However, there may be times when you'd just like a bit more control over the size and appearance of your text while maintaining as much compatibility with older Web browsers as possible. For those times, you can use the officially discouraged but widely used <font> tag.
For example, the following HTML will change the size and color of some text on a page:
<font size=5 color="purple">this text will be big and purple.</font>
The size attribute can take any value from 1 (tiny) to 7 (fairly big), with 3 being the default size. (If you need VERY big fonts, you'll need to use style sheets as explained in Hour 16.)
The color attribute can take any of the following standard color names: black, white, red, green, blue, yellow, aqua, fuchsia, gray, lime, maroon, purple, navy, olive, silver, or teal.
The actual size and exact color of the font depend on each reader's screen resolution and preference settings, but you can be assured that size=6 is a lot bigger than size=2 and that color="red" certainly shows its fire.
You learn more about controlling the color of the text on your pages in Hour 11, "Custom Backgrounds and Colors." That hour also shows you how to create your own custom colors and control the color of text links.
Choosing a Typeface | Next Section

Account Sign In
View your cart