5.1 Link Basics
Hypertext defines a relationship between two objects -- the Web page you are currently viewing (parent) and something else (node). That something else
is often another Web page; however, it could be a specific location on the current Web page (named anchors). It might be an image, a Flash file, a PPT presentation, a PDF file ... the list is not infinite, but it is long.
The link repesents the relationship between the two nodes. In the beginning, hypertext links were text; that is, the presence of the link was reflected in the appearance of text. Traditionally, the text was underlined and blue if you had not yet followed the link. As the Web evolved, hypertext evolved to hypermedia. Now links can be represented by images. This linked system attempts to parallel how our brains work, which is by association rather than by sequence. It also allows authors to create paths through related material with links. Anatomy of a Link http://www.washington.edu/computing/index.html
| | | | |
| site domain path filename
protocol
<a href="http://www.washington.edu/computing/" title="Computing @ University of Washington">UW Computing</a>
This is an absolute link.
<a href="2.html" title="Links to other Web pages">Next Lesson</a>
This is a relative link. All links are surrounded by angle brackets [< >] and, in turn, surround text or images by using a closing tag [</a>]. The <a represents the start of the anchor; the href attribute represents HTML reference; title attribute represents one type of meta-data that can be attached to the link. For more about links, see W3C Specification. If there is no target meta-data in the link string -- the link will open in the current browser window (parent window). There are several ways to force a link to open in a different window; the most simple is to create a named target link. (View source to see the W3C link above.) We will explore three types of links
Next: Links to other Web pages
|
exercise
resources |