Skip to content

Instantly share code, notes, and snippets.

@fredrick
Created June 24, 2011 17:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fredrick/1045245 to your computer and use it in GitHub Desktop.
Save fredrick/1045245 to your computer and use it in GitHub Desktop.
An annotated guide to basic HTML.
learn.html
An annotated guide to basic HTML.
Created by Fredrick Galoso (Updated 2011-06-24)
Public domain, but I'd love some credit. Remix, add, enjoy.
<!----> Are comments.
<!DOCTYPE html>
<html>
<head>
<!--head is invisible, but essential information for an HTML document-->
<title>Hello HTML!</title>
<style>
<!--Keep presentation separate from information-->
body {
background: #e5e5e5;
font-family: Helvetica Neue, Helvetica, Arial, sans-serif;
margin: 5%;
}
h1 {
font-size: 30px;
font-weight: 300;
padding-bottom: 10px;
}
a {
color: #a30006;
}
</style>
</head>
<!--body is the "meat and potatoes" of your document-->
<body>
<h1>This is a top level heading text.</h1>
<h3>Sub-headings are not as important, but useful.</h3>
<h6>You can use &lt;h1&gt; to &lt;h6&gt; in ever decreasing importance.</h6>
<!--& are special HTML symbols. In this case, < and >-->
<p>I am a paragraph.</p>
<br/> <!--Force a line break-->
<a href="http://www.w3.org/TR/html5/sections.html">I am a link.</a>
<div id="hello">I am div with an id of "hello". Think of me as document element.</div>
<span>There are many different tags! Follow the link above to see some.</span>
</body>
<!--Every begininning has an end, don't forget to close <tags></tags>-->
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment