function fensterAuf(url, name, b, h) {
    var eigenschaft,sbreite,shoehe,fenster;
	
	if( typeof( window.innerWidth ) == 'number' ) {
        //Non-IE
        sbreite = window.innerWidth;
        shoehe = window.innerHeight;
    } else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
        //IE 6+ in 'standards compliant mode'
        sbreite = document.documentElement.clientWidth;
        shoehe = document.documentElement.clientHeight;
    } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
        //IE 4 compatible
        sbreite = document.body.clientWidth;
        shoehe = document.body.clientHeight;
    }

	// Fensterpossition linke obere Ecke
	x = (sbreite-b)/2;
	y = (shoehe-h)/2;
	//alert("x: "+x+"y: "+y);
	var eigenschaften ="left="+x+",top="+y+",screenX="+x+",screenY="+y;
	// weitere Attribute hinzufügen
		
    if (typeof(popupWin) != "object"){
        popupWin = window.open(url, name, eigenschaften+'menubar=no, resizeable=no, location=no, scrollbars=no, status=no');
    } 
    else {
        if (!popupWin.closed){
            popupWin.location.href = url;
        } 
        else {
        popupWin = window.open(url, name, eigenschaften+'menubar=no, resizeable=no, location=no, scrollbars=no, status=no');
        }
    }
    popupWin.focus();
    popupWin.moveTo(x,y);
}

function checkLen(textarea)
{
//alert(textarea)
//textarea
var maxLen = 295;
//var txt=document.forms[0].textarea.value;
var txt = textarea.value;
if(txt.length>=maxLen)
    {
     // document.getElementById("message").firstChild.nodeValue = 0;
      textarea.value=txt.substring(0,maxLen);
      document.getElementById("message").firstChild.nodeValue = "Die maximale Zeichenanzahl ist erreicht !";
      //document.getElementById("message").style = "color:red;"

    }
else
    {
	var txtLength = txt.length;
    //document.forms[0].zaehler.value=maxLen-txt.length;
    document.getElementById("message").firstChild.nodeValue = (txt.length)+" von max. "+(maxLen)+" Zeichen";
    }
}



