View Single Post
Old 02-04-2008, 03:50 AM   #4 (permalink)
lingsharma
Junior Member
 
Join Date: Feb 2008
Posts: 7
Default Re: I need help to make a dropdown menu for my site.

This worked for me:

<html>
<head>
<title>
test
</title>

<script language="javascript" type="text/javascript" >

function jumpto(x){

if (document.form1.jumpmenu.value != "null") {
document.location.href = x
}
}

</script>

</head>

<body>

<form name="form1">

<select name="jumpmenu" onChange="jumpto(document.form1.jumpmenu.options[document.form1.jumpmenu.options.selectedIndex].value)">
<option>Jump to...</option>
<option value=http://www.aimst.edu.my>My uni</option>
<option value=http://www.exabytes.com.my>My company</option>

</form>


</body>
</hmtl>
lingsharma is offline   Reply With Quote
Sponsored Links