/* This Library processes the cookie named "lingua2", which can be set to one of 3 values (see bellow) *//*  NEW - it processes also the cookie named "webtrends_id", used  by the 'Webtrends' application      *//*  MODIFIED BY Pavel/absi 03/11/2004  *************************************************************************//*************************************************************************************************************************/var langcookname = "lingua2";// 3 possible langue cookie values :var cookieval = "fr";var webcookname = "webtrends_id";// cookie's persistence (years) :var persist = 10;function computeID() {	// The Form must content the "Remote_Addr" CGI hidden field!	var userIP = document.forms[0].Remote_Addr.value;	var milisec = new Date().getTime();	return ( userIP + "-" + milisec );}function setCookie( cname, cval, addyears ) {// the cookie will expire after the period of "addyears" years	var expirdat = new Date();	expirdat.setYear( expirdat.getFullYear() + addyears );	document.cookie = cname + "=" + escape( cval ) + "; path=/" + ( addyears ? "; expires=" + expirdat.toGMTString() : "" );}function getCookie( cname ) {// gets the cookie value	if ( document.cookie ) {		var cook = document.cookie;		var begin = cook.indexOf( cname + "=" );		if ( begin != -1 ) {			begin += cname.length + 1;			var end = cook.indexOf( ";", begin );			if ( end == -1 ) { end = cook.length; }			return unescape( cook.substring( begin, end ) );		}	}	return( "" );}function cookVerif() {// This function is called by HomePages' onLoad event	var cookval = getCookie( webcookname );	if ( !cookval ) { setCookie( webcookname, computeID(), persist ); }// REM PHP 15/01/07 plus n\u00E9cessaire car langue unique//	cookval = getCookie( langcookname );//	if ( !cookval ) {//		setCookie( langcookname, cookieval, persist );//		return;//	}//	if ((cookval != cookieval) & (window.location != document.forms[0].HomeUrl.value + "/HomePage(Visitor)?OpenForm")){//		window.location = document.forms[0].HomeUrl.value + "/HomePage(Visitor)?OpenForm";//	}}function redirect() {// This function is called by language links in the HomePages left top section	setCookie( langcookname, cookieval, persist );	window.location = document.forms[0].HomeUrl.value + "/HomePage(Visitor)?OpenForm";}function openpage( name ) {	window.location = name;}function opensyntab( lang, log ) {// log expected: 0 or 1	var frm = document.forms[0];	var view = "/TRisk"	var login = log ? "&Login" : "";	window.location = frm.HomeUrl.value + view + "?OpenView&StartKey=A&Count=300&Expand=1" + login;}function openWinCen( mypage, w, h, scroll ) {	var win = null;	var winl = ( screen.width - w ) / 2;	var wint = ( ( screen.height - h ) / 2 ) - 30;	settings = "height=" + h + ",width=" + w + ",top=" + wint + ",left=" + winl;	settings = settings + ",scrollbars=" + scroll + ",toolbar=no,location=no,";	settings = settings + "status=no,menubar=no,resizable=yes,dependent=no";	win = window.open( mypage, "CenteredWindow", settings );	if ( parseInt( navigator.appVersion ) >= 4 ) { win.window.focus(); }}