function NewWindow(mypage, myname, w, h, scroll) {
var winl = (screen.width - w) / 2;
var wint = (screen.height - h) / 2;
winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',resizable'
win = window.open(mypage, myname, winprops)
if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }
}

// Öffnet Remote Fenster für Ortssuche

function remote(url){
win2=window.open(url,"","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=700,height=550")
win2.creator=self
}

// Ruft Ortsseite im Hauptframe auf

function remote2(url){
window.opener.location=url
}

function testformular() {
		fehler = false;
		if (document.anfrage.Vorname.value == "")
			error(document.anfrage.Vorname,"Ihren Vornamen")
		if (document.anfrage.Nachname.value == "")
			error(document.anfrage.Nachname,"Ihren Nachnamen")
		if (document.anfrage.Strasse.value == "")
			error(document.anfrage.Strasse,"die Straße")
		if (document.anfrage.PLZ.value == "" || document.anfrage.Wohnort.value == "" )
			error(document.anfrage.PLZ,"eine PLZ und einen Ort")
		if (document.anfrage.Email.value != "" && ((document.anfrage.Email.value.indexOf ('@') == -1) || (document.anfrage.Email.value.indexOf ('.') == -1)))
			error(document.anfrage.Email,"eine gültige eMail-Adresse")
		if (document.anfrage.Bemerkungen.value.length > 255)
			error(document.anfrage.Bemerkungen,"max. 255 Zeichen")
		return !fehler;
	}
function error(element, text) {
	if (fehler) return;
	window.alert("Bitte "+text+" eintragen!");
	element.focus();
	fehler = true;
	}
