I have this script which I use to link to other sites, but I want to make another one of these, but if I copy all this, except the Javascript, the script breakes and the selects don't go to the given urls anymore.
How could I make this work, the best possible way, with multiple select forms?
<form name="event_type_selector" method="post" action="#">
<select name="url_list" class="event-type-selector-dropdown" onchange="gotosite()">
<option value="" selected="selected" disabled="disabled">Vælg venligst...</option>
<optgroup label="Selection 1:">
<option value="?value-now1">Value-Now 1</option>
</optgroup>
<optgroup label="Selection 2:">
<option value="?value-now2">Value-Now 2</option>
</optgroup>
</select>
<script language="javascript">
function gotosite() {
var URL = document.event_type_selector.url_list.options[document.event_type_selector.url_list.selectedIndex].value;
window.location.href = URL;
}
</script>