HTML and CSS Reference
In-Depth Information
A link on a web
File to load
when link is selected
Text that will be highlighted
<A HREF="../menu.html">Go back to Main Menu</A>
Opening tag
Closing tag
The following example shows a simple link and what it looks like (see Figure 6.2):
Go back to <a href=”menu.html”> Main Menu </a>
How a browser dis-
plays a link.
Task: Exercise 6.1: Linking Two Pages
Now you can try a simple example with two HTML pages on your local disk. You need
your text editor and your web browser for this exercise. Because both the pages you work
with are on your local disk, you don't need to connect to the Internet. (Be patient; you'll
get to do network stuff in the next section.)
Create two HTML pages and save them in separate files. Here's the code for the two
HTML files for this section, called menu.html and claudius.html . What your two pages
look like or what they're called doesn't matter. However, make sure that you insert your
own filenames if you follow along with this example.
The following is the first file, called menu.html :
<!DOCTYPE html><html>
Search WWH ::

Custom Search