Exercise 1 Overview

Create a simple site that links 2 files.

Instructions

Create a new folder called:

  • “1_exercise”.

Open TextWrangler.

Create 2 new documents:

  • Save the first document as: file1.html
  • Save the second document as: file2.html
  • In file1 type “Go to file 2.”
  • In file2 type “Go to file 1.”
  • Link “file 2” to the actual file2.html.
  • Link “file 1” to the actual file1.html.

You will do this with one of the essential building blocks of the internet. This is the anchor element.

  • You are in file1.html
  • Before “file 2” type
  • <a href="file2.html">
  • After “file 2” type
  • </a>

Now do the same in file2.html in order to link back to “file 1”.

Now drag one of the html files that you have created to Firefox. And click on the link. Notice that you are changing between the two web pages you have created.

Congratulations. You have just created your first website.

I know: it’s underwhelming. It’s not sexy at all. But linking files is the basic premise of the Web.

We are going to delve into a lot of terms and definitions. If it starts to seem overwhelming, remember this exercise and that you have already created an ultra-simple site.