/* 	Navigation (sollte caching verhindern !)	Coded: xx.xx.xxxx / xx*/function newWindow(URL, breite, hoehe, withScrollbar) {  	neuesFenster=window.open(URL,"anzeigeFenster","toolbar=no,width=" + breite + ",height=" + hoehe + ",directories=no,status=no,resize=no,scrollbars=" + withScrollbar + ",menubar=no");}function submitForm(URL) {	URL = URL + "?"	for (i=0; i < this.document.formular.length; i++) {	  URL = URL + this.document.formular[i].name + "=" + this.document.formular[i].value + "&"	}	this.location.href=URL;}function submitFormAndClose(URL) {	URL = URL + "?"	for (i=0; i < this.document.formular.length; i++) {	  if (this.document.formular[i].type != "radio" || this.document.formular[i].checked) {	    URL = URL + this.document.formular[i].name + "=" + this.document.formular[i].value + "&"	  }	} 	opener.location.href=URL;	this.window.close();		}function popup(url){	location.href=url}/* 	aktuelles Tagesdatum und Zeit	Coded: xx.xx.xxxx / sb*/function datum(){	heutigesDatum = new Date();	//aktuelles Datum        tt= heutigesDatum.getDate();        mm= heutigesDatum.getMonth();        jj= heutigesDatum.getYear();                tag = heutigesDatum.getDay();                stunde = heutigesDatum.getHours();        minute = heutigesDatum.getMinutes();                       var wochentag = new Array("Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"); 	var monat = new Array("Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember");	if ((jj > 99) && (jj < 1900)) // Netscape	  jj += 1900;	  	if (minute < 10) 	  minute = "0" + minute;		  	document.write(wochentag[tag]+ ", " + tt + "." + monat[mm] + " " + jj + " " + stunde + ":" + minute + " Uhr");}function getDatum(){	heutigesDatum = new Date();	//aktuelles Datum        tt= heutigesDatum.getDate();        mm= heutigesDatum.getMonth();        jj= heutigesDatum.getYear();                tag = heutigesDatum.getDay();                stunde = heutigesDatum.getHours();        minute = heutigesDatum.getMinutes();                       var wochentag = new Array("Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"); 	var monat = new Array("Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember");	if ((jj > 99) && (jj < 1900)) // Netscape	  jj += 1900;	  	if (minute < 10) 	  minute = "0" + minute;		  	return wochentag[tag]+ ", " + tt + "." + monat[mm] + " " + jj + " " + stunde + ":" + minute + " Uhr";}function showConfirm(URL){	URL = URL + "?"	for (i=0; i < this.document.form.length; i++) {	  if (this.document.form[i].name == "bemerkung") {            var rrr = this.document.form[i].value.replace(/\n/g,"<BR>\n")            URL = URL + this.document.form[i].name + "=" + rrr + "&"          }	  else {	    if (this.document.form[i].type == "checkbox"){	        if (this.document.form[i].checked == true) {	          URL = URL + this.document.form[i].name + "=True&"		}		else {		  URL = URL + this.document.form[i].name + "=False&"		}	    }	    else {	      URL = URL + this.document.form[i].name + "=" + this.document.form[i].value + "&"	    }  	  }	}  	neuesFenster=window.open(URL,"anzeigeFenster","toolbar=no,width=550,height=550,directories=no,status=no,resize=no,scrollbars=yes,menubar=no");}function showConfirmSameWin(URL){	URL = URL + "?"	for (i=0; i < this.document.form.length; i++) {	  if (this.document.form[i].name == "bemerkung") {            var rrr = this.document.form[i].value.replace(/\n/g,"<BR>\n")            URL = URL + this.document.form[i].name + "=" + rrr + "&"          }	  else {	    if (this.document.form[i].type == "checkbox"){	        if (this.document.form[i].checked == true) {	          URL = URL + this.document.form[i].name + "=True&"		}		else {		  URL = URL + this.document.form[i].name + "=False&"		}	    }	    else {	      URL = URL + this.document.form[i].name + "=" + this.document.form[i].value + "&"	    }  	  }	}  	window.location=URL;	//neuesFenster=window.open(URL,"anzeigeFenster","toolbar=no,width=550,height=550,directories=no,status=no,resize=no,scrollbars=yes,menubar=no");}function makeConfirm(URL) {	opener.requestSubmitted = true;   			opener.location.href=URL;	this.window.close();		}/* bereitet die Adresse für die Kartenanzeige vor      1. alle Blanks werden eleminiert.   2. Umlaute wie ä, ö und ü werden zu AE, OE und UE konvertiert          Coded: 11.02.2002 SB*/function kartenString( s ){    // zuerst werden alle blanks eliminiert  s = trim (s)	  s = convertUmlaute( s )    return s;  }/* Funktion eliminiert alle Blanks   Coded: 11.02.2002 SB  */function Trim(inString) {  var retVal = "";  var start = 0;  while ((start < inString.length) && (inString.charAt(start) == ' ')) {    ++start;  }  var end = inString.length;  while ((end > 0) && (inString.charAt(end - 1) == ' ')) {    --end;  }  retVal = inString.substring(start, end);  return retVal;}function convertUmlaute( s ){    // die Umlaute werden eliminiert  var retVal = "";  var start = 0;  while (start < s.length){    switch(s.charAt(start))    {    	case "ä":    	  retVal = reVal + "ae"    	break;    	case "Ä":    	  retVal = reVal + "AE"    	break;    	case "ö":    	  retVal = reVal + "oe"    	break;    	case "Ö":    	  retVal = reVal + "OE"    	break;    	case "ü":    	  retVal = reVal + "ue"    	break;    	case "Ü":    	  retVal = reVal + "UE"    	break;    	default:    	 retVal = reVal + s.charAt(start)     	break;    		    } // end switch     } // end while      return retVal;  }/* Funktion erzeugt ein popup mit druck methode   Wert von div id=druck wird aus quelle herausgelesen   Coded: 10.04.2002 MM  */function drucken(){  var y = ""  if (document.all) {    y = "<html><head><title>";    y = y + document.title +"</title>";    y = y + "<link rel=stylesheet href=includes/main.css type=text/css>"    y = y + "</head><body leftmargin=0 topmargin=0 marginwidth=0 marginheight=0 style=\"background-color:#FFFFFF\">";     y = y + "<table width=633 border=0 cellspacing=0 cellpadding=0 bgcolor=\"#FFFFFF\"><tr>";    y = y + "<td width=70 class=inside_text>&nbsp;</td>";    y = y + "<td width=503 class=inside_text>&nbsp;</td>";    y = y + "<td width=60 class=inside_text>&nbsp;</td>";    y = y + "</tr><tr>";    y = y + "<td width=70 class=inside_text>&nbsp;</td>";    y = y + "<td width=503 class=inside_text>";    y = y + "<table width=503 border=0 cellspacing=0 cellpadding=0 bgcolor=\"#FFFFFF\"><tr>";    y = y + "<td width=200 class=inside_text_bold>www.nachmieter.ch</td>";    y = y + "<td width=303 class=inside_text align=right>" + getDatum() + "</td>";    y = y + "</tr></table></td>";    y = y + "<td width=60>&nbsp;</td>";    y = y + "</tr><tr>";    y = y + "<td width=70 class=inside_text>&nbsp;</td>";    y = y + "<td width=503 class=inside_text><img src=images/divider3.gif width=503 height=13></td>";    y = y + "<td width=60 class=inside_text>&nbsp;</td>";    y = y + "</tr><tr>";    y = y + "<td width=70 class=inside_text>&nbsp;</td>";    y = y + "<td width=503 class=inside_text align=right><a href=javascript:this.window.print() class=inside_link>[drucken]</a>&nbsp;&nbsp;<a href=javascript:this.window.close() class=inside_link>[close Window]</a></td>";    y = y + "<td width=60 class=inside_text  bgcolor=\"#FFFFFF\">&nbsp;</td>";    y = y + "</tr><tr>";    y = y + document.all.druck.outerHTML    y = y + "</tr></table>";    y = y + "<table width=633 border=0 cellspacing=0 cellpadding=0 bgcolor=\"#FFFFFF\"><tr>";    y = y + "<td width=70 class=inside_text>&nbsp;</td>";    y = y + "<td width=503 class=inside_text><img src=images/divider3.gif width=503 height=13></td>";    y = y + "<td width=60 class=inside_text>&nbsp;</td>";    y = y + "</tr><tr>";    y = y + "<td width=70 class=inside_text>&nbsp;</td>";    y = y + "<td width=503 class=disclaimer>Copyright © 2002 by Nachmieter.ch.<br>Alle Rechte vorbehalten. Die Reproduktion oder Modifikation ganz oder teilweise ohne schriftliche Genehmigung der SoftBorg Informatik GmbH ist untersagt.<br> All rights reserved. Reproduction or modification in whole or in part without express written permission is prohibited.<br>&nbsp;</td>";    y = y + "<td width=60 class=inside_text>&nbsp;</td>";    y = y + "</tr></table></body></html>";    f1=window.open("", "Druckfenster","toolbar=no,width=650,height=450,directories=no,status=no,resize=no,scrollbars=yes,menubar=no");     f1.document.write(y);    f1.document.close()  }  }
