Objectives of this Tutorial

Generally: To create links to connect pages in a site and link to other sites and email.

Specifically: On completion of this section, you will be able to:

  • Create links to other pages within the same website
  • Create anchors that link to specific areas of a page
  • Create external links

Creating Links

Hyperlinks are an integral part of all web pages. Links are used to add multimedia files, such as images and sound, to a web page, to connect different parts of a large page and perhaps most importantly, to link different pages together.

A link can either be presented as text (hypertext) or as a graphic. A link points to the location of another file (or part of a file). For a link to work, you must supply the path to the file (or place in a file) the link is to. The path can be absolute, document-relative or root-relative.


Tip: You do not need to type in path names when creating links in Dreamweaver. You can simply browse to the file you want. However, you should be aware how links work. The Appendix contains a brief guide to the makeup of URLs.

Also, a link to an HTML document can specify a named location (or anchor) in the document to jump to. You can enter links to named location(s) in the current document too.

Most links are to other HTML documents. When the user clicks the link, the new page is (usually) opened in the current browser window, replacing the previous page.

Any images to display on a web page are put there by means of a link to the graphics file. A link can connect to any type of file. Some files, such as JPEG, GIF or PNG graphics or PDF documents, will open in the browser window. Others will prompt the user to open the file in a suitable application or to save it.

A link can also connect to an email address. In this case, a new mail message is opened with the correct address.

To create links between documents by browsing for a file

  • In the document select the text or image that you want to turn into a link
  • Display the Property Inspector
  • Click the Browse for File folder icon to the right of the Link box

Browse for File button

The Select File dialogue box is displayed.

Select File dialogue box

  • Select the document you want to link to

Note: The path to the document is displayed in the URL: box. By default this is a Document-relative link, but you can change it to a Root-relative link by adjusting the option in the Relative To: box.

  • Click Select