次のようなものを試すことをお勧めします。
test.php
<?php
// Check to see if the form has been submitted.
if(isset($_POST['option'])) {
// If the form has been submitted, force a re-direct to the choice selected.
header('Location: ' . $_POST['option']);
}
?>
<!DOCTYPE html>
<html>
<body>
<form method="post">
<select name="option">
<option value="http://www.google.com">Google</option>
<option value="http://www.yahoo.com">Yahoo</option>
<option value="http://www.bing.com">Bing</option>
<option value="http://www.youtube.com">YouTube</option>
<option value="http://www.mtv.com">MTV</option>
</select>
<button type="submit">Go!</button>
</form>
</body>
</html>
または、@ITroubs のコメントを参照して、jQuery を使用してこれを行うこともできます。
jquery-test.html
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<script type="text/javascript">
function goThere() {
// Grab the drop-down.
var $select = $('#option');
// Grab the value of the option selected within the drop-down.
var url = $select.val();
// Instruct the window to re-direct to the URL.
window.location = url;
}
</script>
</head>
<body>
<form>
<select id="option">
<option value="http://www.google.com">Google</option>
<option value="http://www.yahoo.com">Yahoo</option>
<option value="http://www.bing.com">Bing</option>
<option value="http://www.youtube.com">YouTube</option>
<option value="http://www.mtv.com">MTV</option>
</select>
<button type="button" onclick="goThere();">Go!</button>
</form>
</body>
</html>