// JavaScript Document

var InternetExplorer = navigator.appName.indexOf("Microsoft") != -1;

function aktuelles()
{
	/*
	if (!document.layers)
	{
		document.writeln("  <div id=\"divStayTopLeft\" style=\"position:absolute; margin:0px 0px 0px 10px; padding:0px 3px 0px 3px; font-family:Arial,Helvetica,sans-serif; font-size:13px; font-weight:400; width:150px; background-color:#EEEEEE; border-color:#000000; border-style:solid; border-width:1px;\" align=\"center\">");
	}

	document.writeln("    <layer id=\"divStayTopLeft\" class=\"dynamisches_menu\">");
	document.writeln("      <img src=\"http://www.bgsg.de/bilder/trennung.gif\">");
	document.writeln("      <b><u>Info</u></b><br>");
	document.writeln("      <img src=\"http://www.bgsg.de/bilder/trennung.gif\">");

	document.writeln("    </layer>");
	if (!document.layers)
	{
		document.writeln("  </div>")
	}
	*/
}

function JSFX_FloatTopDiv()
{
	var verticalpos = "fromtop"
	var startX = 3;
	var startY = 100;
	var ns = (navigator.appName.indexOf("Netscape") != -1);
	var d = document;
	function m1(id)
	{
		var el = d.getElementById ? d.getElementById(id) : d.all ? d.all[id] : d.layers[id];
		if(d.layers)
		{
			el.style = el;
		}
		el.sP = function(x, y)
		{
			this.style.left = x;
			this.style.top = y;
		};
		el.x = startX;
		if (verticalpos == "fromtop")
		{
			el.y = startY;
		}
		else
		{
			el.y = ns ? pageYOffset + innerHeight : document.body.scrollTop + document.body.clientHeight;
			el.y -= startY;
		}
		return el;
	}
	window.stayTopLeft = function()
	{
		if (verticalpos == "fromtop")
		{
			var pY = ns ? pageYOffset : document.body.scrollTop;
			ftlObj.y += (pY + startY - ftlObj.y) / 8;
		}
		else
		{
			var pY = ns ? pageYOffset + innerHeight : document.body.scrollTop + document.body.clientHeight;
			ftlObj.y += (pY - startY - ftlObj.y) / 8;
		}
		ftlObj.sP(ftlObj.x, ftlObj.y);
		setTimeout("stayTopLeft()", 10);
	}
	ftlObj = m1("divStayTopLeft");
	stayTopLeft();
}

var unique_id = 12345
var newWinOffset = 0

function popup_mp3_player(title, description, duration, url, width, height)
{
	var wd = 800;
	if (width && !isNaN(width))
	{
		wd = eval(width);
	}

	var ht = 600;
	if (height && !isNaN(height))
	{
		ht = eval(height) + 45 + 82;
	}

	PlayWin = window.open('', unique_id, 'width=' + wd + ',height=' + ht + ',top=' + (screen.availHeight-ht) / 2 +',left=' + (screen.availWidth-wd) / 2 + ',resizable=0,scrollbars=0,titlebar=0,toolbar=0,menubar=0,status=0,directories=0,personalbar=0');
	PlayWin.focus();

	var winContent = "<html>\n";
	winContent += "<head>\n";
	winContent += "  <title>" + description + "</title>\n";
	winContent += "  <link rel='stylesheet' type='text/css' href='http://www.bgsg.de/bgsg.css'>\n";
	winContent += "</head>\n";
	winContent += "<body>";
	winContent += "  <img src='bilder/paulus-blind_und_doch_sehend.jpg' style='padding:0px 0px 0px 0px; margin:0px 0px 0px 0px;'>";
	winContent += "  <table cellspacing='0' cellpadding='0'>\n";
	winContent += "    <tr>\n";
	winContent += "      <td width='" + wd + "' colspan='2'><b>" + title + "</b></td>\n";
	winContent += "    </tr>\n";
	winContent += "    <tr>\n";
	winContent += "      <td width='" + (wd - 50) + "'>" + description + "</td>\n";
	winContent += "      <td width='50'>" + duration + "</td>\n";
	winContent += "    </tr>\n";
	winContent += "    <tr>\n";
	winContent += "      <td>&nbsp</td>\n";
	winContent += "    </tr>\n";
	winContent += "  </table>\n";
	winContent += "  <object width='300' height='45'>\n";
	winContent += "    <param name='scr' value='" +  url + "'>\n";
	winContent += "    <param name='autoplay' value='true'>\n";
	winContent += "    <param name='controller' value='true'>\n";
	winContent += "    <param name='bgcolor' value='#CCCCCC'>\n";
	winContent += "    <embed src='" + url + "' autostart='true' loop='false' width='300' height='45' controller='true' bgcolor='#CCCCCC'></embed>\n";
	winContent += "  </object>\n";
	winContent += "  <center>\n";
	winContent += "    <form style='margin:2px 0px 0px 0px; padding:2px 0px 0px 0px;border-width:1; border-color:#000000;'>\n";
	winContent += "      <input type='button' value='Fenster schließen' onClick='javascript:window.close();' style='margin:0px 0px 0px 0px; padding:0px 0px 0px 0px;'>\n";
	winContent += "    </form>\n";
	winContent += "  </center>\n";
	winContent += "</body>\n";
	winContent += "</html>\n";

	PlayWin.document.write(winContent);
	PlayWin.document.close(); // "Finalizes" new window

	unique_id = unique_id + 1
}

