var langCookieName = "wawaL10n"; // Customize this to a unique string. Ex: "WawaL10n".var defaultLang    = "en";         // Set the default language. Ex: "en" or "fr".var jsl10nKey      = "_jsl10n-";   // The key substring to use for the id of your DIVs. No need to change it.function fnJsl10n() {    var lang = fnGetCookie(langCookieName);//     alert("Cookie: (" + langCookieName + "):[" + lang + "]");	 if ( !lang || '' == lang ) {		  lang = defaultLang;	 }//     alert("Cookie: (" + langCookieName + "):[" + lang + "]");    fnShowLang(document.body, lang);}function fnShowLang(elem, lang) {    var aChildren = elem.childNodes;	 var i = 0;    for (i = 0; i < aChildren.length; i++) {        var sChildId = aChildren[i].id;		  if ( sChildId && '' != sChildId ) {				if (-1 != sChildId.indexOf(jsl10nKey + lang)) {					 aChildren[i].style.display= "block";				}				else if (-1 != sChildId.indexOf(jsl10nKey)) {					 aChildren[i].style.display = "none";          				}				fnShowLang(aChildren[i], lang);		  }    }}function fnSetL10nLang(lang) {    var nextYear = new Date();    nextYear.setFullYear(nextYear.getFullYear() + 1); // Cookie will expire in one year!    fnSetCookie(langCookieName, lang, nextYear);    fnShowLang(document.body, lang);}// [Cookie] Clears a cookiefunction fnClearCookie(cookieName) {   var now = new Date();   var yesterday = new Date(now.getTime() - 1000 * 60 * 60 * 24);   fnSetCookie(cookieName, 'DummyCookieValue', yesterday);}// [Cookie] Sets value in a cookiefunction fnSetCookie(cookieName, cookieValue, expires, path, domain, secure) {   document.cookie =      escape(cookieName) + '=' + escape(cookieValue)      + (expires ? '; expires=' + expires.toGMTString() : '')      + (path ? '; path=' + path : '')      + (domain ? '; domain=' + domain : '')      + (secure ? '; secure' : '');}// [Cookie] Gets a value from a cookiefunction fnGetCookie(cookieName) {   var cookieValue = '';   var posName = document.cookie.indexOf(escape(cookieName) + '=');   if (posName != -1) {      var posValue = posName + (escape(cookieName) + '=').length;      var endPos = document.cookie.indexOf(';', posValue);      if (endPos != -1) cookieValue = unescape(document.cookie.substring(posValue, endPos));      else cookieValue = unescape(document.cookie.substring(posValue));   }   return (cookieValue);}