Home > Information Technology > Web Services > Web Construction Kit > Macromedia Contribute @ VSU

Creating Relative Links with Contribute

Several people have asked how to create a relative link in Contribute. A relative link is a link to a file, image, or other webpage that does not reference the complete domain URL for the link. See the examples at the end of this document. Bear in mind that by default the Contribute client creates links relative to the document root.

Step 1

Select the text that you wish to be a link. Right-click on the selected text and choose Insert Link from the menu that appears.

Step 2

In the Insert Link window, choose the type of page/file to link to from the section at the top of the window.

Step 3

In the bottom left of the Insert Link window, click on the Advanced button.

Step 4

In the text field labeled HREF, enter the path to the page or file that you wish to link to.

Step 5

Click the OK button to save your changes to the link properties.


Step 6

If you click in the link that you just created, you can see what the HREF is by looking in the bottom right of the Contribute window.


Examples:

The URL for this webpage would be:

http://www.valdosta.edu/it/web/vwwwaut/contribute/createnewpage/index.shtml

Absolute

href="http://www.valdosta.edu/it/web/vwwwaut/contribute/createnewpage/index.shtml"

Relative to Site Root

href="/it/web/vwwwaut/contribute/createnewpage/index.shtml"

Relative to Document Root

href="../index.shtml"

My suggestion would be that everyone use links that relative to the site root as much as possible. This ensures that if for some reason the page is moved on the server from one directory to another that the links will still work. There are two possible exceptions to this suggestion:

  1. If the link is pointing to a page that is hosted on a website other than VSU's you will need to use an absolute link.
  2. If the file you are linking to is an image or document such as a PDF or Word file, you might want to just use a link relative to the document.