<de*********@eaton.com> wrote in message
news:11**********************@z14g2000cwz.googlegr oups.com...
On my web site, I have a "Links" link.
Rather than create a separate HTML file listing all the links, I'd like
to create a popup menu (not sure if that's the official name or not).
So, when I click on "Links", I'd like to have a small popup menu appear
with a list of all my links, from which the user can select one.
Is there a way to do this within Javascript?
Dennis Hancy
Eaton Corporation
Cleveland, OH
You might consider a drop-down list; for example:
<html>
<head>
<title>linkpick.htm</title>
<script type="text/javascript">
function link() {
var form = document.form1;
var site = form.links.options[form.links.selectedIndex].value;
if (site == "") return;
location.href = "http://" + site;
}
</script>
</head>
<body>
<form name="form1">
<b>Pick a link:</b><br>
<select name="links" onchange="link()">
<option value="" selected>
<option value="www.google.com">Google
<option value="www.yahoo.com">Yahoo
</select>
</form>
</body>
</html>