//JavaScript - Login-handling//All rights reserved - Copyright by medialink - v2.2a/31.01.2008//---------------------------------------------------------------------------------------------------------------self.name="main";//-----rollover-sectionif (document.images){	var imageov = new Array();	var imageof = new Array();	imageov['intranet'] = new Image();	imageov['intranet'].src = "resource/index_16ov.jpg";	imageof['intranet'] = new Image();	imageof['intranet'].src = "resource/index_16.jpg";}function imgov(i){	if (document.images){		document.images[i].src=imageov[i].src;	}}function imgof(i){	if (document.images){		document.images[i].src = imageof[i].src;	}}//-----capturing keyEventif (ns){    //Netsacpe/Firefox/Mozilla	document.captureEvents(Event.KEYPRESS);	document.onkeypress = keyCheck;}function keyCheck(e){	keyASC = (ns) ? e.which : event.keyCode;	//Mac 13=return(N4M/E5M), 13=return+enter (Moz121M), 3=enter(N4M/E5M); Win 13=return+enter; 0=TAB (Moz121M)	if ((keyASC == 13) || (keyASC == 3)){		formSend();	}	}//-----browsercheckif (!w3c){	top.location.href = "/errors/browserFailed.html";}//-----cookie-functions//Derived from the Bill Dortch code at http://www.hidaho.com/cookies/cookie.txt//Adapted by mediaLINK Switzerland - Version 1.0 / 22.09.2001//-----------------------------------------------------------------------------------var today = new Date();var expiry = new Date(today.getTime() + 365 * 24 * 60 * 60 * 1000);function getCookieVal (offset) {	var endstr = document.cookie.indexOf (";", offset);	if (endstr == -1) { endstr = document.cookie.length; }	return unescape(document.cookie.substring(offset, endstr));	}function GetCookie(name) {	var arg = name + "=";	var alen = arg.length;	var clen = document.cookie.length;	var i = 0;	while (i < clen) {		var j = i + alen;		if (document.cookie.substring(i, j) == arg) {			return getCookieVal (j);			}		i = document.cookie.indexOf(" ", i) + 1;		if (i == 0) break; 		}	return null;	}function DeleteCookie(name,path,domain) {	if (GetCookie(name)) {		document.cookie = name + "=" +		((path) ? "; path=" + path : "") +		((domain) ? "; domain=" + domain : "") +		"; expires=Thu, 01-Jan-70 00:00:01 GMT";		}	}function SetCookie(name,value,expires,path,domain,secure) {  document.cookie = name + "=" + escape (value) +    ((expires) ? "; expires=" + expires.toGMTString() : "") +    ((path) ? "; path=" + path : "") +    ((domain) ? "; domain=" + domain : "") +    ((secure) ? "; secure" : "");	}var cookieOK = false;function cookieCheck(){	SetCookie("cookieChecker","CheckingForCookieFunction",0,"/");	if (GetCookie("cookieChecker") != null){		cookieOK = true;		if (GetCookie("kmeIntranetSessionID") != null){			DeleteCookie("kmeIntranetSessionID","/");		}	}else{		top.location.href = "/errors/nocookies.html";	}}cookieCheck();//-----various functionsfunction defocus(t){	if (t.blur){t.blur()}}function formSend(){	if ((document.login.vt_benutzerID.value=='') || (document.login.vt_passwort.value=='')){		alert('Es fehlt die Eingabe von Benutzer-ID oder Passwort!');	}else{		document.login.submit();	}}function passwordlost(){	if (document.login.vt_benutzerID.value==''){		alert('Geben Sie bitte vorab Ihren Benutzernamen ein.');	}else{		var d = new Date();		var ms = d.getMilliseconds();		top.location.href = "/errors/passwordlost.html?query=" + document.login.vt_benutzerID.value + "&random=" + ms ;	}}//--- end of script
