Contents

HTML CheatSheet

HTML Basics

HTML

Definition

HTML is the standard markup language for Web pages

HTML is NOT a programming language

HTML Elements

1
2
<h1> header1</h1>
<h2> header2</h2>

Paragraph

<p>Text here</p>

Change text fonts:

1
2
3
<i>Italic</i>
<u>Underline</u>
<b>Bold</b>

Section

1
2
3
<section>
    elements...
</section>

Lists

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
Unordered list
<ul>
    <li> Apple </li>
    <li> Banana </li>
</ul>

Ordered list
<ol>
    <li> Apple </li>
    <li> Banana </li>
</ol>
1
<a href="index.html"> Click here </a>

Images

1
<img src="image.png" width="100" height="50" alt="Image Name">

Table

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
<p>
<table>
    <tr>
        <th> head1 </th>
        <th> head2 </th>
    </tr>
    <tr>
        <td> item1 </td>
        <td> item2 </td>
    </tr>
</table>
</p>

Form

1
2
3
4
5
6
7
<form>
    <lable> Type in Name</lable>
    <input name="Name"><br>
    <lable> Date</lable>
    <input name="Date" type="date><br>
    <button>Click</button>
</form>

Commonly used

Insert a new line:

1
<br> New line starts here

Comments:

1
<!-- Comments -->