HTML Document: Skeleton


<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <title> Title here </title>
  link
  <style>
    @import css
  /style
</head>

<body>
 header
    nav
    /nav
 /header

main

article
    section
    /section
/article

aside
/aside

/main

footer
  address
  /address
/footer

</body>
</html>

Grouping Elements

<header>
Used for heading titles, navigational links, introductory content, a logo or icon, authorship information. You can have multiple headers in one document.
<main>
<footer>
<article>
Similar to sections, but specifically for self-contained content that can stand alone or be reused in a different context. Articles can be nested in a section and vice versa.
<section>
A unit used to divide content into smaller chunks, like by chapters or topics. Sections typically include a heading and other content.
<aside>
Identifies content that is separate from, but tangentially related to, surrounding content. Examples include:
  • sidebars
  • pull quotes
  • background information
  • lists of links
  • callouts
  • et cetera...
<div>
Div element. Indicates a division of content. Div and span have no inherent presentation qualities of their own. They are a blank canvas; id and class attributes are applied to individualize and give them meaning. ids are unique, while classes signify a grouping of like types.
<span>
Span element. Indicates a word or phrase for which no text-level element currently exists. It does not automatically add line breaks like div does.

Example:

header
main
article
section
Address element. Used to hold contact information for the website or content creator. Often placed in footers.

Block Elements

Heading Elements

Heading 1

Heading 2

Heading 3

Heading 4

Heading 5
Heading 6

Body Text Elements

<p>

Paragraph element. Main page content goes in the body.

<blockquote>

Blockquote Element

This is a long quotation, or a 'block quote' element.

Content within a blockquote element should itself by contained in other element types, such as paragraph, heading, or list.

<pre>

    Preformatted element.
      display exactly as it is typed, including all w   h   i   t   e   space.
      By default, 
          it also displays 
          in a constant-width
          font.
  

List Elements

<ul>

<ol>

  1. Ordered list element.
  2. <li>
  3. List item element.

<dl>

<dt>
<dd>
Description List
Terms paired with Descriptions.
Term
Description.
Term, Name, or Label

Only dt and dd elements are allowed within a dl element.

Headings or content-grouping elements like paragraphs cannot be put in dt elements, but can be put in dd elements.

Multiple dd elements can be put under one dt element and vice versa.

Misc. Block Elements

<hr>


Horizontal rule element.


<figure> & <figcaption>

'Figure' elements identify content that supports some point in the main text. Figures can be images, video, code snippets, text, a table, almost anything.

Content in a Figure element should be treated and referenced as a self-contained unit; if a figure is removed, the figure as well as the text should still make sense when isolated from the other.

'Figure caption' elements provide a text caption for a figure.

<img>


Inline Elements

<em>
Emphasized text. Used for stressing vocal emphasis on words.
<strong>
Strong text. Used to indicate important, serious, or urgent information.
<s>
Strike-through text. Used to indicate incorrect information.
<small>
Small text. Indicates an addendum or side note to main text.
<q>
Quote text. Used for short quotes.
<abbr>
Abbr text. Used to indicate abbreviations or acronyms.
<cite>
Cite text. Used to identify a reference to another source, such as a book, article, etc.
<dfn>
Defining instance text. Used to highlight the first instance of a word in a document.
<code>
Code text. Used to show code. Also related are var (variable), samp (program sample), kbd (user-entered keyboard strokes), data.
<sub>
Subscript text. [TODO] List the uses of subscript text.
<sup>
Superscript text. [TODO] List the uses of superscript text.
<mark>
Mark text. Used to highlight words.
<time>
Time text. Used to add machine-readable time metadata to text. , Gaithersburg MD.
<del> <ins>
Inserted or deleted text used to indicate parts of a document that have been modified. For example, Deleted TextInserted Text
<b>
Bold text. Used to bold words.
<i>
Italic text. Used to italicize words.
<u>
Underline text. Used to underline words.
<wbr>
Word break element. Used to create a desireable line break opportunity when there is not enough room to fit a whole word comfortably. For example, let us break the word expeditiously. between exped and itiously.
<br>
Break
element. Used to add a line break within a block element.

Class and id attributes are global attributes and can thus be applied to any tag.


For special characters that may confuse the code, 'character escapes' can be used instead. Character escapes begin with an ampersand (&) and end with a semicolon (;) .

Syntax character escapes.
Char. Escape Meaning
< &lt; Less Than
> &gt; Greater Than
" &quot; QUOTation mark
' &apos; APOStrophe
& &amp; AMPersand
?White-space? Character Escapes
Char. Escape Meaning
  &nbsp; Non-Breaking SPace
&ensp; EN SPace
&emsp; EM SPace
&#8203; zero-width space
&zwnj; Zero-Width Non-Joiner
&zwj; Zero-Width Joiner
??? Character Escapes
Char. Escape Meaning
&lsquo; Left Single QUOte
&rsquo; Right Single QUOte
&ldquo; Left Double QUOte
&rdquo; Right Double QUOte
&hellip; Horizontal ELLIPse
© &copy; COPYright
® &reg; REGistered trademark
&trade; TRADEmark
£ &pound; POUND
¥ &yen; YEN
&euro; EURO
&ndash; eN DASH
&mdash; eM DASH