Chapter 2. Progressive Markup and Techniques
As a web developer, you may be eager to implement HTML5’s new features within your website. However, HTML5 is still a budding technology, and browser support for many of its features is spotty at best.
Your excitement at the prospect of a cutting-edge HTML5 site may be tempered by the following questions:
How can I accommodate browsers that have yet to support many of HTML5’s elements?
What are the current best practices for coding a standards-compliant, cross-browser-compatible HTML5 website?
In this chapter you will learn how to test for supported HTML5 features within a browser, and the latest techniques for accommodating those features that aren’t supported. You will learn how to get started quickly with an HTML5 boilerplate template that includes all of the latest tricks, techniques, and best practices for implementing HTML5 technologies. You’ll find out how to validate your HTML5 documents, and even how to code your XHTML/HTML4 documents for future HTML5 upgradability.
The techniques presented in this chapter will give you the confidence to integrate modern HTML5 web technologies within your web pages, even as browser technology is still catching up with them.
2.1. Adding More Semantic Meaning
You want to mark up content correctly.
Apply markup in a semantic manner.
Semantic markup is markup that describes the content it contains, rather than what the content should look like. This means ...