Operation Manual
262
USING DREAMWEAVER
Linking and navigation
Last updated 3/28/2012
Set the relative path of new links
By default, Dreamweaver creates links to other pages in your site using document-relative paths. To use site root–
relative path instead, you must first define a local folder in Dreamweaver by choosing a local root folder to serve as the
equivalent of the document root on a server. Dreamweaver uses this folder to determine the site root–relative paths to
files.
1 Select Site > Manage Sites.
2 In the Manage Sites dialog box, double-click your site in the list.
3 In the Site Setup dialog box, expand Advanced Settings and select the Local Info category.
4 Set the relative path of new links by selecting the Document or Site Root option.
Changing this setting will not convert the path of existing links after you click OK. The setting applies only to new links
you create with Dreamweaver.
Note: Content linked with a site root–relative path does not appear when you preview documents in a local browser unless
you specify a testing server, or select the Preview Using Temporary File option in Edit
> Preferences > Preview In Browser.
This is because browsers don’t recognize site roots—servers do. A quick way to preview content linked with site root–
relative paths is to put the file on a remote server, then select File
> Preview In Browser.
5 Click Save.
The new path setting applies only to the current site.
More Help topics
“Absolute, document-relative, and site root-relative paths” on page 257
“Working with Dreamweaver sites” on page 34
Link to a specific place in a document
You can use the Property inspector to link to a particular section of a document by first creating named anchors.
Named anchors let you set markers in a document, which are often placed at a specific topic or at the top of a
document. You can then create links to these named anchors, which quickly take your visitor to the specified position.
Creating a link to a named anchor is a two-step process. First, you create a named anchor; then you create a link to the
named anchor.
Note: You can’t place a named anchor in an absolutely-positioned element (AP element).
Create a named anchor
1 In the Document window’s Design view, place the insertion point where you want the named anchor.
2 Do one of the following:
• Select Insert > Named Anchor.
• Press Control+Alt+A (Windows) or Command+Option+A (Macintosh).
• In the Common category of the Insert panel, click the Named Anchor button.
3 In the Anchor Name box, type a name for the anchor, and click OK. (The anchor name can’t contain spaces).
The anchor marker appears at the insertion point.
Note: If you do not see the anchor marker, select View > Visual Aids > Invisible Elements.