Hi,

I am looking to change the way that the ez pages are displayed in the ez-page header bar.

Currently they are displayed across the top of the page (and bottom) However instead of this I want to create a sort of quick-links feature where these pages are listed in a dropdown box and when the user selects a page it goes to that page.

I know this can be done with javascript however because most of the data is called dynamically using php I can-not work out how to get it to work.

I can get the drop-down box to display the details of the ez-pages but cant get the javascript function to work to re-direct to the correct page on selection of an option.

I am modifying a tutorial I found to do this.

The tutorial gives this sample code

<head>
<script language="JavaScript">

// Create array to hold four URLs;
var dest = new Array(4);
dest[0] = window.location.href;
dest[1] = "http://www.utexas.edu/";
dest[2] = "http://www.austin360.com/";
dest[3] = "http://www.yahoo.com/";



function go(d) {

// Change location of current window one selected from menu
// d.menu.options.selectedIndex returns a number that corresponds
// to the choice they selected in the pop up menu on the form
// If a user selected the first choice, selectedIndex = 0 and the
// URL will be set to dest[0] or http://www.utexas.edu


window.location.href = dest[d.destination.options.selectedIndex];

// Open new window with selected location
// var x = window.open(dest[d.destination.options.selectedIndex],"New Window");

// To set the URL for another frame in this frameset
// top.framename.location.href = dest[d.menu.options.selectedIndex]);

}
</script>

</head>



<form name="x">
<label for="destination"><h3>Where do you want to go?</h3></label>
<select id="destination" onchange="go(x)">
<option>Quick Links</option>
<option value="1">The University of Texas</option>
<option value="2">Austin 360</option>
<option value="3">Yahoo</option>
<option>Altavista
<option>The Onion
</select>
</form>


Obviously I had changed the <option> tags and surrounded them with a while statement which is already in place and done same with the Array declarations etc.

Can anyone advise please?