

var what = null;
var where = null;
var inTitleOnly = null;
var landing = "http://www.firmenabc.at/landing.aspx";

function doSearch() {
	InitInputs();
	if (what == null || where == null || inTitleOnly == null) {
		return;
	}
	var url = landing + "?";
	url += "what=";
	if (what.value != eval("waterMark_Text_"+searchWhatID)) {
		url += escape(what.value);
	}
	url += "&where=";
	if (where.value != eval("waterMark_Text_"+searchWhereID)) {
		url += escape(where.value);
	}
	else {
		url += escape("Österreich");
	}
	url += "&inTitleOnly=" + inTitleOnly.checked;
	url += "&partner=" + 1;
	window.open(url);
}
function InitInputs() {
	if (what != null && where != null && inTitleOnly != null) {
		return;
	}
	what = document.getElementById("what");
	where = document.getElementById("where");
	inTitleOnly = document.getElementById("inTitleOnly");
	if (what == null) {
		alert("Could not find what");
	}
	if (where == null) {
		alert("Could not find where");
	}
	if (inTitleOnly == null) {
		alert("Could not find inTitleOnly");
	}
}
