* Home
* FrontPage Hosting
* mySQL Hosting
* Dedicated Servers
* Managed Services
* Domain Parking

Direct Email Marketing with Constant Contact

Search our FrontPage Support Area
FrontPage Support Area Site Map


The following are answers to common questions in the Microsoft FrontPage Client Newsgroup:

Adding a Drop Down List Box for Navigation

The script below is for a non-frame site:

  1. At the top of a page in FrontPage Editor, click on Insert, HTML Markup, and add the following code:

    <SCRIPT LANGUAGE="JavaScript">
    <!--
    function showSitePage(form) {
    // Default (form) value is 0
    // Web/HTML page is set with OPTION SELECTED VALUE
    var formindex=form.snPageName.selectedIndex;
    parent.self.location=form.snPageName.options[formindex].value;
    // parent.self refers to the current browser window
    }

    // -->
    </SCRIPT>

  2. Then anywhere underneath the HTML Markup Bot you just added, click on Insert, HTML Markup Bot and modify the following code to suit your needs:

    <FORM NAME="dlSitePages">
    Pages about C. S. Wyatt: <SELECT NAME="snPageName" SIZE="1">
    <OPTION SELECTED VALUE="resume.html" > My Resume;
    <OPTION VALUE="exp.html" > My Tech Background
    <OPTION VALUE="manage.html" > My Management Philosophy
    <OPTION VALUE="bio.html" > My (Short) Biography
    <OPTION VALUE="b1.html" > My Poetry: Vol. 1
    <OPTION VALUE="b2.html" > My Poetry: Vol. 2
    <OPTION VALUE="b3.html" > My Poetry: Vol. 3
    <OPTION VALUE="b4.html" > My Poetry: Vol. 4
    <OPTION VALUE="b5.html" > My Poetry: Vol. 5
    <OPTION VALUE="b6.html" > My Poetry: Vol. 6
    <OPTION VALUE="deadrich.html"> A Story by Me - The Homeless Ball
    <OPTION VALUE="return.html" > A Story by Me - Returning
    <OPTION VALUE="reviews.html" > Reviews of This Site!
    </SELECT>
    <INPUT TYPE="button" VALUE="View" OnClick="showSitePage(this.form)">
    </FORM>

If you want to add multiple drop down list boxes for navigation, make sure you give each form a different name as in "FORM NAME=" .

Here is the script for a frame-based site:

Substitue the ** for the name if thge frame you wish it to go to. This should work!

<!--
function showSitePage(form) {
// Default (form) value is 0
// Web/HTML page is set with OPTION SELECTED VALUE
var formindex=form.snPageName.selectedIndex;
parent.**.location=form.snPageName.options[formindex].value;
// parent.** refers to the frame window
}
// -->
</script><form name="dlSitePages">
<p align="center">&nbsp;&nbsp;&nbsp;
<select name="snPageName" size="1">
<option value="/tour/default.htm">Main Tour Page</option>
<option value> </option>
<option value="/tour/pilbara.htm">Pilbara</option>
<option value="/roebourne.htm">Roebourne</option>
<option value="/tour/history.htm">Aboriginal History</option>
</select>
<input type="button" value=" GO! " onclick="showSitePage(this.form)"> </p>
</form>

Keiron

Additional Resources
  FP: How To Redirect A Browser From a List Box Choice

Christopher Scott Wyatt for the code, and Peter Abraham for the instructions.


Direct Email Marketing with Constant Contact


Dynamic Net, Inc.

Legal Notices; Copyright © 1996 - 2006 Dynamic Net™, Inc. All rights reserved.
See our privacy statement for questions on how we use information gained by our site.
Managed Services provided by We Manage Servers; hosted by Dynamic Net, Inc.
Last updated: Thursday November 16, 2006 18:22 -0500