Skip to content

Instantly share code, notes, and snippets.

@michaeltroy
Last active August 29, 2015 14:02
Show Gist options
  • Save michaeltroy/f46bfb7a42926ac80fc8 to your computer and use it in GitHub Desktop.
Save michaeltroy/f46bfb7a42926ac80fc8 to your computer and use it in GitHub Desktop.
HTML cheat sheet
<!-- Heading levels -->
<h1>Heading 1</h1>
<h2>Heading 2</h2>
<h3>Heading 3</h3>
<h3>Heading 4</h3>
<!-- Paragraph. -->
<p>This is a paragraph.</p>
<!-- Ordered list. -->
<ol>
<li>List item one</li>
<li>List item two</li>
<li>List item three</li>
</ol>
<!-- Unordered list. -->
<ul>
<li>List item one</li>
<li>List item two</li>
<li>List item three</li>
</ul>
<!-- Image link. -->
<img src="path/to/cat-image.jpg" alt="Image of a cat" />
<!-- Link. -->
<a href="http://www.website.au/page.html">text to link</a>
<!--
Basic table.
This should get us by unless we have a case that is a bit more complex.
Documentation: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/table
-->
<table>
<caption>Table caption</caption>
<thead>
<tr>
<th>Table header</th>
</tr>
</thead>
<tbody>
<tr>
<td>Table data</td>
</tr>
<tr>
<td>Table data</td>
</tr>
<tr>
<td>Table data</td>
</tr>
</tbody>
</table>
@michaeltroy
Copy link
Author

Wow, what an excellent reference.
alt text

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment