Site Navigation

Jun 8, 2011

HTML5 Cheat Sheet Part I: A Simple HTML5 Template

I posted a link to my Markdown Cheat Sheet earlier this week. This is the first post on the key steps I went through to create that HTML page.

The first step was to create a basic, simple HTML5 template. Here is what I came up with.

Simple HTML Template

   1 <!DOCTYPE html>
   2 <html lang="en">
   3 <head>
   4   <meta charset="utf-8"/>
   5   <title>Simple HTML5 Template</title>
   6 </head>
   7 <body>
   9 <h2>Header 2</h2>
  10 <p>This is a very simple HTML 5 template.</p>
  12 </body>
  13 </html>


The key lines are 1, 2, and 4. On line 1 the new DOCTYPE is set. After that, just set the language and character set. Once I added these 3 things, the page would load in any modern browser (Firefox, Chrome, Safari, IE9).

See my detailed How-to for reference material here.
Post a Comment

Favorite Links Feed