Skip Navigation.

Dreamweaver: Using Frames

Once you've made your frameset, you need to make pages that use your frames. To do this, you need to tailor your links to direct the browser to change other frames.

Linking using frames

When you're making links in pages that will appear within a frameset, you need to make sure you fill in the "Target" attribute, found in the properties window for anything that will become a link. The Target tells the browser where to put the link you've indicated.

Linking within the same frame
If no target attribute is included with a link, the browser assumes that you want the link to appear in the same frame as the link is in. In other words, to make a link change its own frame, you need not worry about the target attribute.

Using links to change other frames
To change the content of another frame with a link (as with a navigation bar), you need to set the target property to indicate the name of the frame you're aiming for (hence the use of the word target). After you make your link, follow these steps:

  1. Click on the linked object. Notice that the properties window includes a text box called "Target" (Below).

  2. In the Target text box, type the name of the frame you want the link to change. In our example (see our example pages), the navigation bar uses the target "body" to indicate the frame that we've named "body." You can also select a target from the pull-down menu if it is offered
    Dreamweaver Properties Window
    Dreamweaver Properties Window
    (Click for enlargement)

Once you've filled in the target and the link, you should be ready to use your frames!

Other uses for the "Target" attribute

Here are two other useful ways to use the target attribute:

Return to full screen display
Sometimes, you will want to make a link from within your frameset that leaves the frame setup behind. To do this, you need simply use on of the special "Target" values: _top. Simply choose "_top" from the pull-down menu or type it in the Target text box yourself.

Open a second browser window
Occasionally, you'll have a link that you want users to peruse, but you'll also want to avoid having them leave your site to do so. Using the _new value is just the way to do this. Simply choose "_new" or type it in the Target text box yourself. Another way to open a new browser window is to use a name that you have not assigned to a frame. Then, later on, you can send other links to this window just as if it were a frame.

Back