To create a link in HTML, you need two things:
To create a link in HTML you use the tags <A> and </A>. The <A> is also known as an anchor tag, as it can also be used to create anchors for links. The "A" tag has several attributes. An example of a link looks like this:
<A HREF="../lists/Lists.HTML">Go to Lists Page</A>
The HREF stands for HypertextReFerence which specifies the URL that the link points to. The text "Go To Lists Page" is the text that appears on the screen that the view can select to go to the link location.
Relitive pathnames draw a path from the current directory to the target file. Here are 4 examples of relitive pathnames:
Absolute pathnames refer to files by their exact location starting with a / then the name of the disk where they reside. Here are some examples of absolute pathnames:
A link to a page on the web looks just like a link to a file on your own machine, except instead of a pathname to a file on your machine you use a URL to the page on the web. Here is an example:
<A HREF="http://www.cern.ch/">Cern Home Page</A>
To do this you must create an Anchor at the location where you want to jump to. You create the anchor in nearly the same way that you create the link. Here is the code to make an anchor at the above title:
<A>NAME="Anchor1">Here</A>
Here is how you make the link to jump to this section. Notice that the HREF attribute is different than the previous links HREF attribute. There is no path to a file name, instead there is a # mark that denotes the current file then the name of the anchor. At the end of the link there is the familiar hypertext to mark the link in the browser.
<A HREF=#Anchor1>Go to above title</A>
To jump to a specific location in another file, you need to supply a path to that file followed by the name of the anchor. Here is an example of the code to do this:
<A HREF="../lists/Lists.HTML#Glossary Lists">Go to Lists, Glossary Lists</A>