Location.href not working!

Can anyone tell me why the following code is not working please?
The function is called when a user clicks a button.

function goToStock(){
	if (document.getElementById("top_search").value=="used") {
	else if (document.getElementById("top_search").value=="van") {
	else if (document.getElementById("top_search").value=="bike") {
	else if (document.getElementById("top_search").value=="nearlynew") {
	else if (document.getElementById("top_search").value=="motability") {

I’ve been having a look at some other coding and I can get this to work if I put the url into the select option value. Problem is I need to have another value in there to get the rest of the coding to work on the page.
Can anyone tell me how to modify the code below so that I can check to see what value has been selected in the dropdown and then assign a url accordingly?

The code is below. Any help would be greatly appreciated with this.

<script type="text/javascript">
function goTo() {
var sE = null, url;
if(document.getElementById) {
sE = document.getElementById('urlList');
} else if(document.all) {
sE = document.all['urlList'];
if(sE && (url = sE.options[sE.selectedIndex].value)) {
location.href = url;

<select id="urlList" size="1">
<option value="">Select a link...</option>
<option value="http://www.google.com/">Google</option>
<option value="http://www.mozilla.org/">Mozilla.org</option>
<option value="http://www.opera.com/">Opera.com</option>
<input type="button" value="Go!" onclick="goTo();">