Relative Links

A relative link directs the browser to a file whose location is specified in relation to the file containing the link. This means that the browser starts with the address (URL) of the current webpage, and alters it to get the address (URL) of the page to load when the link is clicked.

For example, the glossary page contains the relative link <A HREF="relative.html">a relative link</A>. This tells the computer to look in the same directory as the tutorial page for a file named relative.html.

To send the browser down into a subdirectory, use the subdirectory name followed by a slash. For example, to get from my teaching page to the tutorial, the relative link is HREF="tutorial/howto.html".

To send the browser up to a higher level directory, use two dots ".." followed by a slash. For example, to get from this page back to my homepage, the relative link is HREF="../index.html".