Creating the HTML File
<!DOCTYPE html>
<html>
<head>
<meta> </meta>
</head>
<body> </body>
</html>
<!DOCTYPE html>
All HTML documents must start with a type declaration
<head> </head>
Sets off the title and other information that isn't displayed on the web page itself
<meta> </meta>
Adds information to the head. Such as keywords/description.
<html> </html>
Creates an HTML document
<body> </body>
Sets off the visible portion of the document
Text Tags
<pre> </pre>
Creates preformatted text
This is an example using "pre"
<h1> </h1>
Creates the largest headline
This is an example using "h1"
<h2> </h2>
Creates the 2nd largest headline
This is an example using "h2"
<h3> </h3>
Creates the 3rd largest headline
This is an example using "h3"
<h4> </h4>
Creates the 4th largest headline
This is an example using "h4"
<h5> </h5>
Creates the 5th largest headline
This is an example using "h5"
<h6> </h6>
Creates the smallest headline
This is an example using "h6"
<b> </b>
Creates bold text
This is an example using "b"
<i> </i>
Creates italic text
This is an example using "i"
<tt> </tt>
Creates teletype, or typewriter-style text
This is an example using "tt"
<cite> </cite>
Creates a citation, usually italic
This is an example using "cite"
<em> </em>
Emphasizes a word (with italic or bold)
This is an example using "em"
<strong> </strong>
Emphasizes a word (with italic or bold)
This is an example using "strong"
Tables
<table> </table>
Creates a table
<th> </th>
Sets off the table header (a normal cell with bold, centered text)
<tr> </tr>
Sets off each row in a table
<td> </td>
Sets off each cell in a row
This is an example of how a table will look
Col 1 |
Col 2 |
Col 3 |
Row 1 Col 1 |
Row 1 Col 2 |
Row 1 Col 3 |
Row 2 Col 1 |
Row 2 Col 2 |
Row 2 Col 3 |
Table Attributes
<table border="1"> </table>
Sets width of border around table cells
<table cellspacing="1"> </table>
Sets amount of space between table cells
<table cellpadding="1"> </table>
Sets amount of space between a cell’s border and its contents
<td colspan="2"> </td>
Sets number of columns a cell should span (default=1)
<td rowspan="4"> </td>
Sets number of rows a cell should span (default=1)
<td nowrap> </td>
Prevents the lines within a cell from being broken to fit