// PopUp Funktion -----------------------------------------------------------------
function popUp( url, breite, hoehe, name )
{
	var popup = window.open(url,name,'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=yes,resizable=0,width='+breite+',height='+hoehe+",left = 575,top = 225");

	if( navigator.appName.substring(0,8) == "Netscape" )
	{
		popup.location = url;
		popup.opener = self;
	}
	
	if (popup) return false;
	  else return true;
}
// PopUp Funtion Ende ---------------------------------------------------------------

// Link bestätigen  -----------------------------------------------------------------
function conf( text, url )
{
	if ( confirm( text ) )
	{
		location.href=url; 		/* sehende Seite */
	}
	else
	{
		/* abbrechen Seite oder Verweis */
	}
}
// Link bestätigen  Ende-------------------------------------------------------------

// Checkboxen aktivieren  -----------------------------------------------------------------
var Marker = false;
checkboxes = document.getElementsByTagName("input");

function selectall()
{
    if(!Marker)
    {
        for (i=0; i<checkboxes.length ; i++)
	    {
	            if (checkboxes[i].type == "checkbox") checkboxes[i].checked=true;
	    }

        Marker = true;
    }
    else
    {
        for (i=0; i<checkboxes.length ; i++)
	    {
	            if (checkboxes[i].type == "checkbox") checkboxes[i].checked=false;
	    }

        Marker = false;
    }
}
// Checboxen aktivieren  Ende-------------------------------------------------------------



// Nur Zahlen aktzeptieren
var oldstring
function CheckNumbers(obj) {
    var text = obj.value;
    if(isNaN(text)==true){
        obj.value=oldstring;
    }else {
        oldstring=text;
        if(text=="" || text=="undefined") {
            text="";
        }
    }
}

$(document).ready(function(){
	initHovers();
});
function initHovers()
{
	$("#topNavi input").focus(function () {
	    $(this).css({
			"background-color" : "#EBEBEB",
	    	"border-color" : "#7d1616"
	    });
    });
    $("#topNavi input").blur(function () {
         $(this).css({
			'background-color':'#fff',
	    	'border-color':'#000'
	    });
    });

}