(Redirected from Hyperlinks)
A hyperlink (often referred to as simply a link), is a reference or navigation element in a document to another section of the same document, another document, or a specified section of another document, that automatically brings the referred information to the user when the navigation element is selected by the user.
On the web
To make a hyperlink in HTML, use the anchor tag:
<a href="URL" title="Description of link">link text</a>.
There are three different types of hyperlinks on the web, absolute, relative, and inline links.
Absolute links are generally used to link to a document on a separate Website and are represented as a complete URL.
|HTML||The <a href="http://google.com" title="Google is a good search engine">search engine</a>.|
|HTML||The <a href="https://gustavus.edu/gribly/">Gribly</a> allows you to search for directory information.|
Relative links are used to link to a document that is located under the same domain name and are represented as a partial URL. There are two different types of relative links: relative from the current document and relative from the web root.
Relative from the current document
|HTML||Learn about the <a href="World_Wide_Web" title="World Wide Web on Technology Services' wiki">World Wide Web</a>.|
|HTML||The <a href="../athletics/index.php" title="Athletics at Gustavus">Athletics</a> site is one of our best.|
|HTML||Web Services has a list of <a href="webservices/frequently-asked-questions/">frequently asked questions</a>.|
Relative from the web root
|HTML||Learn about <a href="/gts/Hyperlink" title="Hyperlink on Technology Services' wiki">hyperlinks</a>.|
Inline links are used to link to information within the same document and are represented by a pound sign (#) followed by the target anchor's name.
In order for an inline link to work, you need to give it a target to point to using the anchor tag:
|HTML||The <a href="#chapter-three" title="Jump to the third chapter">third chapter</a> of this book.|