function loadToponiemen(type, value) {
	getServerData(aspLink + "?alias=" + siteAlias + "&view=" + viewAlias + "&page_alias=toponiem" + "&type=" + type + "&value=" + value, eval("updateToponiemen_" + type));
}

function updateToponiemen_plaats(html) {
	document.getElementById("plaats").disabled=true;

	var container = document.getElementById("plaatsContainer");
  container.innerHTML = html; 
}

function updateToponiemen_strandpaal(html) {
	var container = document.getElementById("strandpaalContainer");
  container.innerHTML = html;
}

function initToponiemen() {
	var type = "plaats";
	var inputProvincie = document.getElementById("provincie");
	var inputPlaats = document.getElementById("plaats");
	//alert(inputProvincie.options + ": " + inputProvincie.selectedIndex + " --> " + inputProvincie.options[inputProvincie.selectedIndex].value);
	//alert(inputPlaats.options[1].value);
	if (inputProvincie != null && inputPlaats != null){
		if (inputProvincie.options != null) {
			if (inputProvincie.options[inputProvincie.selectedIndex].value != "") {
				getServerData(aspLink + "?alias=" + siteAlias + "&view=" + viewAlias + "&page_alias=toponiem" + "&type=" + type + "&value=" + inputProvincie.options[inputProvincie.selectedIndex].value + "&selected=" + inputPlaats.options[1].value, eval("updateToponiemen_" + type));
			}
		}
	}
}

addEvent(window, 'load', initToponiemen);
