In this program when the user selects an option in the select object, the loadPage() function is invoked by the onclick event handler of button, passing the select object as an argument. The URL associated with each option is stored as the option's value attribute, or value property in terms of javascript. The selected option is list.options[list.selectedIndex] becuase list.selectedIndex is an integer represented the index of the selected option. The value property is used property is used to access the URL of the selected object,which is then to assigned to loaction.href, in order ti load the page to the browser window.

Code:
<html>
<head>
<title>Url Option With Button</title>
<script>
function loadPage(list)'user defined function loadPage() called when the user clicks on button
{
location.href=list.options[list.selectedIndex].value'helps in changing the page from the cuurent to what is selected on the basis of selected index.
}
</script>
</head>
<body>
<form>
<select>
<option value="http://www.cnn.com/">cnn'option with address of cnn website
<option value="http://www.rediff.com/">Rediff
<option value="http://www.msn.com/">Msn
<option value="http://www.Yahoo.com/">Yahoo
</select>
<input type="button" value="load page" onclick="loadPage(this.form.elements[0])">
</form>
</body>
</html>