//Saving-Dialog anzeigen
function save_it() {	
	window.document.getElementById('saving_hidden').style.display = '';	
	window.document.getElementById('frame').style.display = 'none';
}

//Übersicht OnMouseOver
function highlight(element, color) {
	element.style.backgroundColor = color;
	//element.style.cursor = 'pointer';
}

//Hand als Cursor
function makepointer(element) {
	element.style.cursor = 'pointer';
}

//Pop-Up Fenster
function pop_up(link, breite, hoehe) {
	Fenster = window.open(link, "", "width="+breite+", height="+hoehe+", left=30, top=30, resizable=yes, scrollbars=yes");
	Fenster.focus();	
}

//"Sicher?"-Abfrage
function sure(zlink) {
	var del = confirm("Sind Sie sicher, dass Sie diesen Eintrag löschen wollen?");
	if(del) {
		location.href = zlink;
		return(true);
	}
}

//Versteckt z.B. Buttons hinter Auswahlboxen
function verstecken(myarray) {			
	for (var i = 0; i < myarray.length; i++)			
		window.document.getElementById(myarray[i]).style.display = 'none';
}

//GetElementByClassName
function getElementsByClassName(class_name) {
	var all_obj,ret_obj = new Array(), j=0, teststr;

	if (document.all)
		all_obj=document.all;
	else 
		if(document.getElementsByTagName && !document.all)
			all_obj=document.getElementsByTagName("*");

	for(i=0;i<all_obj.length;i++) {
		if(all_obj[i].className.indexOf(class_name)!=-1) {
			teststr=","+all_obj[i].className.split(" ").join(",")+",";
			if(teststr.indexOf(","+class_name+",")!=-1) {
				ret_obj[j]=all_obj[i];
				j++;
			}
		}
	}
	
	return ret_obj;
}

//Style einer Klasse ändern
function change_Class(Class, Style, Wert) {
	objekte = getElementsByClassName(Class);
	for (y=0; y<objekte.length; y++) {
		eval('objekte[y].style.'+Style+'="'+Wert+'"');
	}
}
