MMDT1021 Chapter 6 Notes - page 1

Creating a Link to Another Web Page

Link to a relative page.
The page is in the same directory/folder as the calling page.
Code Result
This is some text before the link.
<a href="chapter6p2.htm">MMDT1021 Chapter 6 Notes - page 2</a>
This is some text after the link.
This is some text before the link. MMDT1021 Chapter 6 Notes - page 2 This is some text after the link.
 
Link to a relative page.
The page is in a directory/folder under the calling page.
In this case, the page is in the "examples" sub-directory.
Code Result
This is some text before the link. <a href="examples/chapter6p1a.htm"> Example 6 page 1A </a> This is some text after the link. This is some text before the link. Example 6 page 1A This is some text after the link.
 
Link to a relative page.
The page is in a directory/folder above the calling page.
Note the "../" in the link - the linked directory in one level up.
Code Result
This is some text before the link. <a href="../schedule.htm">MMDT1021 Class Schedule</a> This is some text after the link. This is some text before the link. MMDT1021 Class Schedule This is some text after the link.
 
Link to an absolute page.
The page is in any directory/folder on the same server.
Note the link begins with a "/" - this makes it an absolute link.
Code Result
This is some text before the link. <a href="/filesutilities/filesutilites.htm">Files and Utilites </a> This is some text after the link. This is some text before the link. Files and Utilites This is some text after the link.
 
Link to an absolute page on a server.
The page is in any directory/folder on any server.
Note the link begins with a "http://" - this makes it an absolute link to a server/page.
Code Result
This is some text before the link. <a href="http://www.ridgewater.edu"> Ridgewater College</a> This is some text after the link. This is some text before the link. Ridgewater College This is some text after the link.

Not all web sites have "www" in the beginning of their web address.  Examples are http://cst.ridgewater.edu and this website which is http://mmdt1021.ridgewater.net

Not all web sites have three parts in their web web address.
The city of Hutchinson has five parts. http://www.ci.hutchinson.mn.us
McLeod county has five parts. http://www.co.mcleod.mn.us

Case sEnSiTiVe
Note that some Web Servers are case sensitive. If a Web Server is case sensitive, "index.html" is not the same as "Index.html" or "bitsnbytes.htm" is not the same as "BitsnBytes.htm. Be aware of this when creating links.

Servers running Unix or Linux are case sensitive.  Servers running Windows are not case sensitive, but they are case aware.  Therefore is is always a good idea to always pay attention to case of file names to avoid any problems.

Short Links
Don't make link labels too long. Keep them short. Only use the key word or words to make your link label.

Click Here
Try not to use "Click Here" for a label. Instead use key words that already exist in your text to identify the link.