Introduction to HTML

Starting the page:
<title>Stuff (appears in window title bar)</title>
<body> content...

Ending the page:

Tags that don’t need a close Meaning
<p> New paragraph (one line of space between)
<br> New line (no space between)
<hr> “Horizontal Rule” (just a line)

Tags that DO need a </close> Meaning
<h1>, <h2> , etc. Headings (big, bold text)
<center> Center text
<b> Bold
<u> Underline
<i>, <em> Italic (“emphasis”)
<blockquote> Indent both sides + space above and below

Tags with multiple parts Meaning
<ul>Un-ordered list:
<li>web development
<li>web design

Ordered list <ol>Building a web page:
<li>basic tags -- html, head, body
<li>add content
<li>save, upload, preview

&lt; &gt; &nbsp; &amp; &quot; &copy;

All links have three main parts:

1. Where do you want the link to take you? Put it between the quotes in the line below:
<a href=”http://wheretogo”>

2. What do you want to show in your page and be “clickable”? Put it next:
<a href=”http://wheretogo”>Click here!

3. Close the tag:
<a href=”http://wheretogo”>Click here!</a>

Absolute links:
<a href=””>
<a href=””>

Relative links:
<a href=”somepage.html”> in this directory

<a href=”pagesfolder/somepage.html”> in a directory called “pagesfolder”
which is in this directory

<a href=”../somepage.html”> in the directory above this one

<a href=”../../../somepage.html”> in the directory above the directory above the directory above this one


The picture tag has no /close part.

<img src=”name_of_picture.jpg” alt=”picture of whatever”>
<img src=”images/name_of_picture.gif”>
<img src=””> -- may not work!

Valid types: .jpg, .gif, sometimes .png -- these are the only 3 that work
Don’t forget the “alt=” attribute for handicapped people’s browsers.

Linking pictures

<a href=”page2.html”><img src=”page2_button.jpg”></a>

Next: Fonts, Tables