|
|
|
|
|
|
Although many people find the ability to add images and colors to their documents to be the principal appeal of web page authoring, the real magic of HTML lies in the creation of hypertext links.
The simple act of clicking a link can do something as mundane as providing a definition for a word or as exciting as taking you to another part of the planet.
To create a link, begin a hypertext anchor tag:
<a href=add a destination address (URL):
"http://www.jcu.edu.au">and an onscreen representation for the link:
Another Part of the PlanetThen close the anchor tag:
</a>The complete hypertext link in your HTML document would look like this:
<a href="http://www.jcu.edu.au">Another Part of the Planet</a>And onscreen it would look like this:
Another Part of the Planet
Images can also be used as hypertext links. To use an image as the anchor in the above example, you would replace the text "Another Part of the Planet" with an image tag:
<a href="http://www.jcu.edu.au"><img src="earth.gif" alt="Earth from Space"></a>(The alt="Earth from Space" tag provides alternative text for viewers using text-only browsers.)
The onscreen result would be:
![]()