

var syn = "";
var news = "";
var myload = false;



var LayerUpdate = 200;

//---fuer den IE-MAC
function openIEmac(){
if(browser.indexOf("ie") >= 0 || browser == "ns6" && (isMac()) != -1){
	if (document.referrer.indexOf('careers/index.htm')!=-1){
	document.all['layer3'].style.visibility = 'visible';
	document.all['layer4'].style.visibility = 'visible';
	}
}
}
//---fuer den IE-MAC
function closeIEmac(){
if(browser.indexOf("ie") >= 0 || browser == "ns6" && (isMac()) != -1){
	document.all['layer3'].style.visibility = 'hidden';
	document.all['layer4'].style.visibility = 'hidden';
	}
}
function fromcountry(){
if (document.referrer.indexOf('country')!=-1 || location.href.indexOf("#Jobs_and_Career")!=-1 ){
	site_1();}
}
function layerPos(){

	var w = getDocumentProperty ("clientWidth");
	var ref = getLayerStyleRef ('layer3');
	var syn = getLayerStyleRef ('layer4');
	ref.left = ((w-720)/2);
	syn.left = ((w-720)/2);
	LayerTimer=setTimeout("layerPos()", LayerUpdate);
	if(browser.indexOf("ie") >= 0 || browser == "ns6"){
		if (!(location.href.indexOf("#Jobs_and_Career")!=-1)&&!(navigator.appVersion.indexOf("Mac") != -1)){
		ref.visibility = 'hidden';
		syn.visibility = 'hidden';
		}
	}
}


function site_1(){


layerPos();
var ref = getLayerStyleRef ('layer3');
var syn = getLayerStyleRef ('layer4');

if (browser == 'ns4'){
	ref.visibility = "show";
	syn.visibility = "show";
}
else if (browser.indexOf("ie") >= 0 || browser == "ns6"){
	ref.visibility = 'visible';
	syn.visibility = 'visible';
	
}
}


var mode = 0;

function checkPlugIn(i_name,i_version) {
	if (i_name=='flash') {
		if (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"] && navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin) {
			if (navigator.plugins && navigator.plugins["Shockwave Flash"])// && !(ie4 && mac))
			mode = 1;
		}
		else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0
		   	&& (navigator.userAgent.indexOf("Windows 9")>=0 || navigator.userAgent.indexOf("Windows NT")>=0)) {
			document.write('<SCRIPT LANGUAGE=VBScript\> \n');
			document.write('on error resume next \n');
			document.write('mode = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.3")))\n');
			document.write('</SCRIPT\> \n');
		}
		return mode;
	}
	// QUICKTIME
	if (i_name=='quicktime') {
		if (navigator.mimeTypes && navigator.mimeTypes["video/quicktime"] && navigator.mimeTypes["video/quicktime"].enabledPlugin) {
			if (navigator.plugins && navigator.plugins["QuickTime"])// && !(ie4 && mac))
			mode = 1;
		}
		else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0
		   	&& (navigator.userAgent.indexOf("Windows 9")>=0 || navigator.userAgent.indexOf("Windows NT")>=0)) {
			document.write('<SCRIPT LANGUAGE=VBScript\> \n');
			document.write('on error resume next \n');
			document.write('mode = (IsObject(CreateObject("QuickTimeCheckObject.QuickTimeCheck.1")))\n');
			document.write('</SCRIPT\> \n');
		}
		return mode;
	}
}

/*
Funktion insertObject()
Leistung:	Fuegt ein Objekt ein, z.B. ActiveX-Control
Parameter:	i_plugin	fuer die Darstellung des Objektes erforderliches PlugIn
			i_path		relativer Pfad zum Objekt bzw. zum Fallback (WICHTIG: Angabe ohne file extension)
			i_name		Name des Objektes
			i_width		Breite des Objektes
			i_height	Hoehe des Objektes
			i_bgcolor	Hintergrundfarbe als Hex-Zahl
FALLBACK: gleicher dateiname wie normale datei
*/
function insertObject(i_plugin, i_path, i_name, i_width, i_height, i_bgcolor) {
	// FLASH
	if(i_plugin=='flash') {
		if (checkPlugIn(i_plugin)){
			document.write('<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"');
			document.write(' codebase="http://active.macromedia.com/flash2/cabs/swflash.cab#version=3,0,0,0"');
			document.write(' ID="' + i_name + '" WIDTH="' + i_width + '" HEIGHT="' + i_height + '">');
			document.write(' <PARAM NAME=movie VALUE="' + i_path + '.swf"> ');
			document.write(' <PARAM NAME=quality VALUE=high> ');
			document.write(' <PARAM NAME=menu VALUE=false> ');
			document.write(' <PARAM NAME=bgcolor VALUE=#' + i_bgcolor + '> ');
			document.write('<EMBED SRC="' + i_path + '.swf"');
			document.write(' NAME=' + i_name + ' swLiveConnect="TRUE" WIDTH="' + i_width + '" HEIGHT="' + i_height + '"');
			document.write(' QUALITY="autohigh" MENU="false" BGCOLOR="#' + i_bgcolor + '"');
			document.write(' TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">');
			document.write('</EMBED>');
			document.write('</OBJECT>');
			
		}
		else {
			document.write('<img src="' + i_path + '.jpg" width="' + i_width + '" height="' + i_height + '" border="0" usemap="#fallback">')
		}
	}
	if(i_plugin=='quicktime') {
		if (checkPlugIn(i_plugin)){
			document.write('<EMBED SRC="' + i_path + '.mov"');
			document.write(' BGCOLOR="#' + i_bgcolor + '" WIDTH="' + i_width + '" HEIGHT="' + i_height + '"');
			document.write(' CONTROLLER="true" BORDER="0" PLUGINSPAGE="http://www.apple.com/quicktime/download/" cache="true">');
		}
		else {
			document.write('<img src="' + i_path + '.gif" width="' + i_width + '" height="' + i_height + '" border="0">')
		}
	}
}

function resetSelection (theform, theitem)
{
	if (isMac() && getBrowser() == "ie4") return;
	eval ("document." + theform + "." + theitem + ".selectedIndex = 0");
}

function browseTo (url)
{
	if (url) location.href = url;
}

