View Full Version : Jump to url from dropdown list selection

01-11-2007, 02:03 PM
Hi guys, I wonder can you help, I am creating a dropdown menu for my site because I have run out of space for a nav bar, what I would love to do is create a dropdown list that when an option is selected will jump to a specific URL.

Can you help please?



01-11-2007, 02:25 PM
Try this:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<html xmlns="http://www.w3.org/1999/xhtml">
<title>Jump to url from dropdown list selection</title>
<script type="text/javascript">
function jump(obj){
if(obj.selectedIndex != 0){
alert('Please Select!!!');
<form name="form1">
<select name="jumpMenu" onchange="jump(this.form.jumpMenu)">
<option selected value=""> Please Select </option>
<option value="http://google.com/"> Google </option>
<option value="http://altavista.com/"> AltaVista </option>
<option value="http://yahoo.com/"> Yahoo </option>

01-11-2007, 02:32 PM
Hey Thanks Martial, worked great....

Dave. :thumbsup:

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum