/* 
onclick="delbox('formular', 'FormularName', 'Name was zu löschen ist');"
onclick="delbox('url', '/netforge/...', 'Name was zu löschen ist');"
*/

var delbox_url = '';
var deltext2 = '.';
browser = '';

var browserName = navigator.appName;
var browserVersion = parseInt(navigator.appVersion);

if (browserName == "Microsoft Internet Explorer" &&
	browserVersion == 4 &&
	navigator.appVersion.indexOf("MSIE 6.0") != -1) {
	browser = "ie6";
}

function delbox (what, url, deltext) {
	
	var myWidth = 0, myHeight = 0;
	if( typeof( window.innerWidth ) == 'number' ) {
    	//Non-IE
	    win_h = window.innerHeight;
		win_w = window.innerWidth;
	  } else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
		//IE 6+ in 'standards compliant mode'
		win_h = document.documentElement.clientHeight;
		win_w = document.documentElement.clientWidth;
	} else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
		//IE 4 compatible
		win_h = document.body.clientHeight;
		win_w = document.body.clientWidth;
	}

	var win_s	= document.getElementsByTagName('body')[0].scrollHeight;
	
	delbox_what = what;
	delbox_url = url;
	
	var deltext2 = deltext;
	
	if (win_h <= win_s) {document.getElementById('delbg').style.height = (win_s + 16) + 'px';}
	
	if (browser == "ie6") {
		document.getElementById('delbox').style.position = 'absolute';
		document.getElementById('delbox').style.top = (win_s - win_h + 140) + 'px';
	} else {
		document.getElementById('delbox').style.top = ((win_h / 2) - 70) + 'px';
	}
	document.getElementById('delbox').style.left = ((win_w / 2) - 125 ) + 'px';	

	document.getElementById('delwas').firstChild.nodeValue = deltext2;	
	document.getElementById('delbg').style.display = "block";
	document.getElementById('delboxbg').style.display = "block";
}
	
function delbox_action (mode) {
	if (mode == 1) {
		if (delbox_what == 'url') {
			document.location.href = delbox_url;
		} 
		if (delbox_what == 'formular') {
			var string = 'document.' + delbox_url + '.submit();'
			eval(string);
		} 
	} else {
		document.getElementById('delbg').style.display = "none";
		document.getElementById('delboxbg').style.display = "none";
	}
}

document.write(""
+"<div id=\"delbg\"></div>"
+"<div id=\"delboxbg\">"
+"<table height=100% width=100%><tr><td>"
+"	<div id=\"delbox\">"
+"	<table border=0 width=100% cellpadding=1>"
+"		<tr>"
+"			<td colspan=2 align=right><a href=\"#\" onclick=\"return delbox_action(0);\"><img src=\""+ staticurl +"/grafik/submit_x.gif\" width=\"15\" height=\"15\" border=\"0\" style=\"padding:2px\"></a></td>"
+"		</tr>"
+"		<tr>"
+"			<td colspan=2><h1><span id=\"delwas\">.</span></h1></td>"
+"		</tr>"
+"		<tr>"
+"			<td><a href=\"#\" onclick=\"return delbox_action(1);\"><img src=\""+ staticurl +"/grafik/buttons/red_ok.gif\" width=\"82\" height=\"19\" border=\"0\"></a></td>"
+"			<td><a href=\"#\" onclick=\"return delbox_action(0);\"><img src=\""+ staticurl +"/multi/"+ multiurl +"/submit_abbrechen.gif\" width=\"82\" height=\"19\" border=\"0\"></a></td>"
+"		</tr>"
+"	</table>"		
+"	</div>	"
+"</td></tr></table>"
+"</div>"
+"</div>"
+"");		