var IE6=!1,IE7=!1,IE8=!1,IE9=!1,FIREFOX7=!1,FIREFOX6=!1,FIREFOX5=!1,FIREFOX4=!1,FIREFOX35=!1,FIREFOX3=!1,FIREFOX2=!1,FIREFOX=!1,NETSCAPE7=!1,NETSCAPE=!1,OPERA9=!1,OPERA=!1,SAFARI=!1;AUTRE=!1;var strChUserAgent=navigator.userAgent,intSplitStart=strChUserAgent.indexOf("(",0),intSplitEnd=strChUserAgent.indexOf(")",0),strChStart=strChUserAgent.substring(0,intSplitStart),strChMid=strChUserAgent.substring(intSplitStart,intSplitEnd),strChEnd=strChUserAgent.substring(strChEnd);
strChMid.indexOf("MSIE 7")!=-1?IE7=!0:strChMid.indexOf("MSIE 8")!=-1?IE8=!0:strChMid.indexOf("MSIE 9")!=-1?IE9=!0:strChMid.indexOf("MSIE 6")!=-1?IE6=!0:strChEnd.indexOf("Firefox/7")!=-1?FIREFOX7=!0:strChEnd.indexOf("Firefox/6")!=-1?FIREFOX6=!0:strChEnd.indexOf("Firefox/5")!=-1?FIREFOX5=!0:strChEnd.indexOf("Firefox/4")!=-1?FIREFOX4=!0:strChEnd.indexOf("Firefox/3.5")!=-1?FIREFOX35=!0:strChEnd.indexOf("Firefox/3")!=-1?FIREFOX3=!0:strChEnd.indexOf("Firefox/2")!=-1?FIREFOX2=!0:strChEnd.indexOf("Safari/")!=
-1?SAFARI=!0:strChEnd.indexOf("Firefox")!=-1?FIREFOX=!0:AUTRE=!0;typeof errorColor=="undefined"&&(errorColor={1:"#80920C",0:"#880000"});includeTraduct={close:{FR:"Fermer",EN:"close"},select:{FR:"S\u00e9l\u00e9ctionnez",EN:"Select"},the_email:{FR:"Votre email",EN:"Your email"},reinit_password:{FR:"R\u00e9initialiser le mot de passe",EN:"Reset Password"},loading:{FR:"Chargement",EN:"Loading"},send_msg:{FR:"Envoyer le message",EN:"Send message"}};typeof language_js=="undefined"&&(language_js="FR");
String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"")};function isdefined(a){return typeof a!="undefined"}function ClearDummyOption(){dojo.query(".dummyOption").forEach(function(a){dojo.destroy(a)})}
function testCookies(a,c){accepteCookies=navigator.cookieEnabled?!0:!1;if(typeof navigator.cookieEnabled=="undefined"&&!cookieEnabled)document.cookie="petitTest",accepteCookies=document.cookie.indexOf("petitTest")!=-1?!0:!1;accepteCookies||document.write("<div class="+c+">"+a+"</div>")}
function responseJson2HTML(a,c){var d=void 0;if(a!=null){var b=a[0];a[1]!=null&&(d=a[1])}var b=a,e=dojo.fromJson(c);e.url!=null&&jumpMenuGo(e.url);e.focus!=null&&(dojo.byId(e.focus).parentNode.parentNode.parentNode.scrollIntoView(),dojo.byId(e.focus).focus(),MarkAsErr(dojo.byId(e.focus)));if(e.responseDiv!=null){b=e.responseDiv;dojo.byId(b)==null&&(b=b.substring(0,b.length-9));if(e.msg!=null)dojo.byId(b).innerHTML=e.msg;e.urlMsg!=null&&submitFonction(null,b,e.urlMsg)}if(e.responseHTMLDiv!=null)ResponseNodeId=
dojo.byId(e.responseHTMLDiv),ResponseNodeId.innerHTML=e.renduHtml;e.msg!=null&&b!=null?(showInvisibleDiv(b),e.noerror==void 0&&(dojo.animateProperty({node:b,delay:0,duration:1,properties:{backgroundColor:{end:""},color:{end:"black"}}}).play(),backcolorend=e.result?errorColor[1]:errorColor[0],dojo.animateProperty({node:b,delay:0,duration:500,properties:{color:"white",backgroundColor:{start:"white",end:backcolorend}}}).play()),e.result&&isdefined(d)&&d(e)):b!=null&&e.urlMsg==null&&maskInvisibleDiv(b);
e.javascriptCode!=null&&eval(e.javascriptCode)}function jumpMenuGo(a){(SAFARI||FIREFOX2||FIREFOX3)&&!FIREFOX35&&window.location.reload();document.location=a}function refreshPage(){document.location=document.location;(SAFARI||FIREFOX||FIREFOX2||FIREFOX3||FIREFOX4||FIREFOX5||FIREFOX6||FIREFOX7||IE6||IE7||IE8||IE9)&&!FIREFOX35&&document.location.reload()}function popup(a,c){window.open(a,c,"scrollbars=yes")}
function showWaitBox(){mouseWaitingOn();if(IE6==!1)waitBox=document.createElement("div"),waitBox.id="waitBox",waitBox.innerHTML=includeTraduct.loading[language_js]+" ",image=document.createElement("img"),image.src="/images/ajax-loader.gif",image.width=15,image.height=15,waitBox.appendChild(image),document.body.appendChild(waitBox)}function hideWaitBox(){IE6==!1&&(waitBox=dojo.byId("waitBox"),document.body.removeChild(waitBox));mouseWaitingOff()}
function submitFonction(a,c,d,b,e,f,g,h){if(c!=null)dojoxBaseUrl=dojo.baseUrl,dojoxBaseUrl=dojoxBaseUrl.substring(1,dojoxBaseUrl.length-1)+"x/";setTimeout("showWaitBox()",150);return dojo.xhrPost({url:d,preventCache:!0,failOk:!0,form:a,content:f,load:function(a){if(a!=null){if(c!=null&&dojo.byId(c)!=null)dojo.byId(c).innerHTML=a,dojo.animateProperty({node:c,delay:0,duration:500,properties:{opacity:{start:0,end:1},"-ms-filter":"progid:DXImageTransform.Microsoft.Alpha(Opacity=100)"}}).play();b!=null&&
b(e,a);if(g!=null){if(g.parentNode.onclickSave!=null&&h!=!0)g.parentNode.onclick=g.parentNode.onclickSave;g.parentNode!=null&&g.parentNode.removeChild(g)}setTimeout("hideWaitBox()",150)}},error:function(a){console.debug("Error: ",a);if(c!=null&&dojo.byId(c)!=null)dojo.byId(c).innerHTML="Error : "+a.message;setTimeout("hideWaitBox()",150)}})}
function submitFormsendfile(a,c,d,b,e){dojo.io.iframe.send({url:d,contentType:"multipart/form-data",handleAs:"html",form:dojo.byId(a),handle:function(a){dojo.byId(c).innerHTML=a.body.innerHTML;b!=null&&b(e,a)},error:function(a){console.error("Error: ",a)}})}function showDiv(a){a!=null&&dojo.byId(a)!=null&&(dojo.removeClass(a,"cache"),dojo.addClass(a,"montre"))}function maskDiv(a){a!=null&&dojo.byId(a)!=null&&(dojo.removeClass(a,"montre"),dojo.addClass(a,"cache"))}
function maskInvisibleDiv(a){a!=null&&dojo.byId(a)!=null&&(dojo.removeClass(a,"montre"),dojo.addClass(a,"cacheInv"))}function showInvisibleDiv(a){a!=null&&dojo.byId(a)!=null&&(dojo.removeClass(a,"cacheInv"),dojo.addClass(a,"montre"))}
function chargerCSS(a){var c=document.createElement("link");c.setAttribute("rel","stylesheet");c.setAttribute("href",a);c.setAttribute("type","text/css");c.setAttribute("media","screen");c.setAttribute("id","testcsss");document.getElementsByTagName("head")[0].appendChild(c)}function chargerJS(a){var c=document.createElement("script");c.setAttribute("type","text/javascript");c.setAttribute("src",a);document.getElementsByTagName("head")[0].appendChild(c)}
function copy2Field(a,c){destinationNode=dojo.byId(c);if(destinationNode.value=="")destinationNode.value=a.value}function clearInput(a){a.value="";a.onkeyup()}
function populateSelect(a,c,d,b,e){select=dojo.byId(a);deleteNode(select);a=window.document.createElement("option");a.value="";d=window.document.createTextNode(d);a.appendChild(d);select.appendChild(a);for(key in c)if(c[key].search(RegExp(b,"i"))!=-1){a=window.document.createElement("option");a.value=key;if(e==key)a.selected=!0;d=window.document.createTextNode(c[key]);a.appendChild(d);select.appendChild(a)}}
function populateSelectWhithCat(a,c,d,b,e,f){select=dojo.byId(a);filterValue=b==null?"":b.value=="Saisie rapide"?"":b.value;deleteNode(select);b=window.document.createElement("option");b.value="";d=window.document.createTextNode(d);b.appendChild(d);select.appendChild(b);for(cat in c)if(e==null||e==""||cat==e)for(key in c[cat])if(noaccent(c[cat][key].LABEL).search(RegExp(noaccent(filterValue),"i"))!=-1){b=window.document.createElement("option");b.value=key;if(key==f)b.selected=!0,SAFARI&&b.focus();
d=window.document.createTextNode(c[cat][key].LABEL);b.title=c[cat][key].LABEL;b.appendChild(d);key==f&&(keyselected=key);select.appendChild(b)}dojo.byId(a).selectedIndex=dojo.byId(a).selectedIndex}
function populateSelectWhithCatAndLocaliz(a,c,d,b,e,f,g){select=dojo.byId(a);filterValue=b==null?"":b.value=="Saisie rapide"?"":b.value;deleteNode(select);b=window.document.createElement("option");b.value="";d=window.document.createTextNode(d);b.appendChild(d);select.appendChild(b);for(localis in c)if(f==localis)for(cat in c[localis])if(e==null||e==""||cat==e)for(key in c[localis][cat])if(noaccent(c[localis][cat][key].LABEL).search(RegExp(noaccent(filterValue),"i"))!=-1){b=window.document.createElement("option");
b.value=key;if(key==g)b.selected=!0,SAFARI&&b.focus();d=window.document.createTextNode(c[localis][cat][key].LABEL);b.title=c[localis][cat][key].LABEL;b.appendChild(d);key==g&&(keyselected=key);select.appendChild(b)}dojo.byId(a).selectedIndex=dojo.byId(a).selectedIndex}function reloadRegionsSelect(a,c){liste=dojo.fromJson(c);populateSelectWhithCat(a,liste,"- "+includeTraduct.select[language_js]+" -",null,null)}
function desactivateInputInId(a){dojo.query("#"+a+" input").forEach(function(a){a.disabled=!a.disabled})}function onEnterClick(a,c,d){var b=null;d==void 0&&(d=!0);if(d){if(a.which)b=a.which;else if(a.keyCode)b=a.keyCode;if(13==b)return c!=null&&setTimeout("dojo.byId('"+c+"').onclick();",100),!1}}var alreadyInAfficheFormulaire=!1;
function afficheFormulaire(a,c,d,b,e){if(alreadyInAfficheFormulaire==!1){alreadyInAfficheFormulaire=!0;dojo.require("dijit.Dialog");var f;b!=null&&(styleCss="width: "+b+"px;",inputWidth="width: "+(b-25)+"px;");f=new dijit.Dialog({title:a,"class":"subForm4MssErreur",style:styleCss+"font-size:12px;"});a='<form id="formMsg'+f.id+'" class="formMsg">';a+='<div class="AficheErreur" id="mssErreurSendMsg'+f.id+'"></div>';a+='<input name="contentResponseId" type="hidden" value="'+d+'"/>';e!=null&&(a+='<input name="hiddenMsg" type="hidden" value="'+
e+'"/>');a+='<input name="dialogId" type="hidden" value="'+f.id+'"/>';a+='Sujet :<br/><input name="sujetMsg" type="text" value="'+c+'" style="'+inputWidth+'" /><br/>';a+='Message :<br/><textarea class="ValRequ" title="le message" id="contentMsg'+f.id+'" name="contentMsg" style="'+inputWidth+'height:100px;"></textarea><br/>';a+='<br/><div class="lienjavaCenter"><a  id="sendMsgBtt'+f.id+'" onClick="dialoghide=validation(\'formMsg'+f.id+"','/compte/index/send-msg',null,null,null,event);\" >"+includeTraduct.send_msg[language_js]+
"</a></div><br/>";a+="</form>";f.attr("content",a);f.onFocus=function(){dojo.byId("contentMsg"+f.id).focus()};f.show();alreadyInAfficheFormulaire=!1}}
function afficheFormulaireContact(a,c,d,b,e){if(alreadyInAfficheFormulaire==!1){mouseWaitingOn();alreadyInAfficheFormulaire=!0;dojo.require("dijit.Dialog");var f;b!=null&&(styleCss="width: "+b+"px;",inputWidth="width: "+(b-25)+"px;");f=new dijit.Dialog({title:a,"class":"subForm4MssErreur",style:styleCss+"font-size:12px;"});a='<form id="formMsg'+f.id+'" class="formMsg">';a+='<div class="AficheErreur" id="mssErreurSendMsg'+f.id+'"></div>';a+='<input name="dialogId" type="hidden" value="'+f.id+'"/>';
a+='Votre e-mail* :<br/><input id="emailMsg'+f.id+'" title="votre email" class="ValRequ checkEmail" name="email" type="text" style="'+inputWidth+'" /><br/>';a+='<input name="type" value="'+e+'" type="hidden" />';e==1&&(a+='Soci\u00e9t\u00e9 :<br/><input name="societe" type="text" style="'+inputWidth+'" /><br/>');e==2&&(a+='Centre de Recherche / Etablissement :<br/><input name="labs" type="text" style="'+inputWidth+'" /><br/>');a+='Sujet* :<br/><input name="sujetMsg" title="un sujet" class="ValRequ" type="text" value="'+
c+'" style="'+inputWidth+'" /><br/>';a+='Message* :<br/><textarea class="ValRequ" title="le message" name="contentMsg" style="'+inputWidth+'height:100px;"></textarea><br/>';a+='<br/><div class="lienjavaCenter"><a  id="sendMsgBtt'+f.id+'" onClick="dialoghide=validation(\'formMsg'+f.id+"','/index/index/send-msg',null,null,null,event);\" >"+includeTraduct.send_msg[language_js]+"</a></div><br/>";a+='<div id="responseformContact'+f.id+'"></div>';a+="</form>";f.attr("content",a);f.onFocus=function(){dojo.byId("emailMsg"+
f.id).focus()};mouseWaitingOff();f.show();alreadyInAfficheFormulaire=!1}}
function afficheFormulaireBug(a,c,d,b,e,f,g){if(alreadyInAfficheFormulaire==!1){mouseWaitingOn();alreadyInAfficheFormulaire=!0;dojo.require("dijit.Dialog");var h;f!=null&&(styleCss="width: "+f+"px;",inputWidth="width: "+(f-25)+"px;");h=new dijit.Dialog({title:a,"class":"subForm4MssErreur",style:styleCss+"font-size:12px;"});a='<form id="formMsg'+h.id+'" class="formMsg">';a+='<div class="AficheErreur" id="mssErreurSendMsg'+h.id+'"></div>';a+='<input name="dialogId" type="hidden" value="'+h.id+'"/>';
a+='URL* :<br/><input name="URL" title="l\'URL" class="ValRequ" type="text" value="'+d+'" style="'+inputWidth+'" /><br/>';a+='Votre e-mail* :<br/><input id="emailMsg'+h.id+'" title="votre email" class="ValRequ checkEmail" name="email" type="text" value="'+b+'" style="'+inputWidth+'" /><br/>';a+='<input name="type" value="'+g+'" type="hidden" />';a+='Sujet* :<br/><input name="sujetMsg" title="un sujet" class="ValRequ" type="text" value="'+c+'" style="'+inputWidth+'" /><br/>';a+='Type de bug : <select name="typeBug" title="le type de bug" class="ValRequ"><option value="0" label="- '+
includeTraduct.select[language_js]+' -">- '+includeTraduct.select[language_js]+' -</option><option value="Bug technique/lien cass\u00e9">Bug technique/lien cass\u00e9</option><option value="Ergonomie">Ergonomie</option><option value="Esth\u00e9tique">Esth\u00e9tique</option><option value="Pertinence des r\u00e9sultats">Pertinence des r\u00e9sultats</option><option value="Autre">Autre</option></select><br/>';a+='Message* :<br/><textarea class="ValRequ" title="le message" name="contentMsg" id="contentMsg'+
h.id+'" style="'+inputWidth+'height:100px;"></textarea><br/>';a+='S\u00e9v\u00e9rit\u00e9 du bug : <select name="severite" title="la s\u00e9v\u00e9rit\u00e9 du bug" class="ValRequ"><option value="0" label="- '+includeTraduct.select[language_js]+' -">- '+includeTraduct.select[language_js]+' -</option><option value="Bloquant">Bloquant</option><option value="Majeur">Majeur</option><option value="Mineur">Mineur</option></select><br/>';a+='<br/><div class="lienjavaCenter"><a  id="sendMsgBtt'+h.id+'" onClick="dialoghide=validation(\'formMsg'+
h.id+"','/index/index/send-msg-bug',null,null,null,event);\" >"+includeTraduct.send_msg[language_js]+"</a></div><br/>";a+='<div id="responseformBug'+h.id+'"></div>';a+="</form>";h.attr("content",a);h.onFocus=function(){dojo.byId("contentMsg"+h.id).focus()};mouseWaitingOff();h.show();alreadyInAfficheFormulaire=!1}}
function afficheFormulaireLostPassword(a,c,d){if(alreadyInAfficheFormulaire==!1){mouseWaitingOn();alreadyInAfficheFormulaire=!0;dojo.require("dijit.Dialog");var b;d!=null&&(styleCss="width: "+d+"px;",inputWidth="width: "+(d-25)+"px;");b=new dijit.Dialog({title:a,"class":"subForm4MssErreur",style:styleCss+"font-size:12px;"});a='<form id="formMsg'+b.id+'">';a+='<div class="AficheErreur" id="mssErreurSendMsg'+b.id+'"></div>';a+='<input name="dialogId" type="hidden" value="'+b.id+'"/>';a+=includeTraduct.the_email[language_js]+
'* :<br/><input id="emailMsg'+b.id+'" title="'+includeTraduct.the_email[language_js]+'" class="ValRequ checkEmail" name="email" onkeypress="return onEnterClick(event,\'sendMsgBtt'+b.id+'\');" type="text" style="'+inputWidth+'" value="'+dojo.byId("username").value+'" /><br/>';a+='<br/><div class="lienjavaCenter"><a  id="sendMsgBtt'+b.id+'" onClick="validation(\'formMsg'+b.id+"','/index/auth/lostpassword?response=responseLostPassword"+b.id+"',null,null,null,event);\" >"+includeTraduct.reinit_password[language_js]+
"</a></div><br/>";a+='<div id="responseLostPassword'+b.id+'"></div>';a+="</form>";b.attr("content",a);b.onFocus=function(){dojo.byId("emailMsg"+b.id).focus()};mouseWaitingOff();b.show();alreadyInAfficheFormulaire=!1}}
function popin(a,c,d){if(alreadyInAfficheFormulaire==!1){mouseWaitingOn();alreadyInAfficheFormulaire=!0;dojo.require("dijit.Dialog");var b;b=new dijit.Dialog({title:a,content:d,autofocus:!0,refocus:!1,duration:500,"class":"subForm4MssErreur",style:"font-size:12px;",onShow:function(){this.containerNode.innerHTML="";div=document.createElement("div");div.innerHTML=d;if(c!=null)div.style.width=c+"px";this.containerNode.appendChild(div)},onCancel:function(){dojo.query("#"+b.id+" textarea,#"+b.id+" input,#"+
b.id+" select,#"+b.id+" radio").forEach(function(a){a.blur()})},onHide:function(){setTimeout(function(){b.destroyRecursive()},dijit.defaultDuration*2)}});b.show();mouseWaitingOff();alreadyInAfficheFormulaire=!1;return b}}function popinUrl(a,c,d,b){submitFonction(null,null,c,showPopin,{titre:a,xSize:d,jsCode:b})}function updateDialog(a){dialogNode=dijit.byId(a);dialogNode._size();dialogNode._position()}
function txt2Hml(a){a=a.replace(/(\r\n|[\r\n])/g,"<br/>");a=a.replace(/(\r|[\r])/g,"<br/>");return a=a.replace(/(\n|[\n])/g,"<br/>")}function showPopin(a,c){dialog=popin(a.titre,a.xSize,c);dojo.query("#"+dialog.id+" form").forEach(function(a){var b=document.createElement("input");b.type="hidden";b.name="idDialog";b.value=dialog.id;a.appendChild(b)});a.jsCode!=null&&eval(a.jsCode)}
function closeDialogAfter(a){a.idDialog!=void 0&&dijit.byId(a.idDialog).hide();list=a.listFieldsChange;for(i in list)if(dojo.byId(i)!=null)theNode=dojo.byId(i),list[i]!=""?dojo.removeClass(theNode.parentNode,"cache"):dojo.animateProperty({node:theNode.parentNode,delay:2,duration:250,properties:{backgroundColor:{start:"white",end:"#6D6D6D"}},onEnd:function(a){dojo.addClass(a,"cache");a.style.backgroundColor="white"}}).play(),theNode.innerHTML=txt2Hml(list[i]),dojo.animateProperty({node:theNode,delay:2,
duration:250,properties:{backgroundColor:{start:"white",end:"#6D6D6D"}},onEnd:function(a){dojo.animateProperty({node:a,delay:2,duration:250,properties:{backgroundColor:{start:"#6D6D6D",end:"white"}}}).play()}}).play();list=a.listFieldsHrefChange;for(i in list)if(dojo.byId(i)!=null)theNode=dojo.byId(i),theNode.href=list[i];if(a.bar_percent!=void 0)barwidth=736*(a.bar_percent/100)+5,dojo.animateProperty({node:"progressBarPlein",delay:2,duration:500,properties:{width:{end:barwidth}}}).play(),dojo.byId("bar_percent_label").innerHTML=
a.bar_percent+"%",a.emptyDivId!=void 0&&dojo.addClass(a.emptyDivId,"empty"),a.fulledDivId!=void 0&&dojo.removeClass(a.fulledDivId,"empty")}function mouseWriteTxt(a){offsetCss=81;offsetwidth=50;if(!a)a=window.event;waitMouseDiv=dojo.byId("theWaitMouseDiv");waitMouseDiv.style.left=a.screenX+document.documentElement.scrollLeft-offsetwidth+"px";waitMouseDiv.style.top=a.screenY+document.documentElement.scrollTop-offsetCss+"px"}
function mouseWaitingOn(){IE6==!1?setTimeout('dojo.addClass(document.body,"waiting");',100):(dojo.byId("theWaitMouseDiv").style.display="block",document.onmousemove=mouseWriteTxt)}function mouseWaitingOff(){IE6==!1?setTimeout('dojo.removeClass(document.body,"waiting");',150):(document.onmousemove=null,dojo.byId("theWaitMouseDiv").style.display="none")}var inithelp=!1;
function initialiseHelp(a){inithelp==!1&&(mouseWaitingOn(),inithelp=!0,dojo.query(".bttHelp_R, .bttHelp_L").forEach(function(a){var d=document.createElement("div");d.setAttribute("id","subDiv"+a.id);a.appendChild(d)}),setTimeout("initHelpTooltips()",200),setTimeout("dijit.byId('subDiv"+a.id+"DropDownButton').openDropDown();",300))}
function showHelp(a,c,d){a="subDiv"+a;dojo.require("dijit.form.DropDownButton");dojo.require("dijit.Dialog");styleCss="";d!=null&&(styleCss="width: "+d+"px;",inputWidth="width: "+(d-25)+"px;");c=new dijit.TooltipDialog({style:styleCss+"font-size:12px;",content:HTMLentitiesdecode(c)+'<br/><div class="clearfloat_B"></div>',autofocus:!0});c.startup();var b=new dijit.form.DropDownButton({label:"",id:a+"DropDownButton",dropDown:c});dojo.style(b.domNode,"visibility","hidden");IE6==!0&&dojo.style(b.domNode,
"display","none");dojo.connect(dojo.byId(a).parentNode,"onclick",function(){b.openDropDown()});dojo.byId(a).parentNode.appendChild(b.domNode);mouseWaitingOff()}
function transfert2list(a,c,d){selecteur=dojo.byId(a);listeEtab=dojo.byId(c);listeEtab.selectedIndex=-1;d!=null&&select_by_value(selecteur,d);SelectIndex=selecteur.selectedIndex;if(SelectIndex!=-1){nbrEtabChoisi=listeEtab.length;pasChoisi=!0;for(i=0;i<nbrEtabChoisi&&pasChoisi;){if(selecteur.options[SelectIndex].value==listeEtab.options[i].value)pasChoisi=!1,etabSup=listeEtab.options[i],listeEtab.options[i].selected="SELECTED";i++}if(pasChoisi&&selecteur.options[SelectIndex].value!="")etabSup=document.createElement("option"),
etabSup.value=selecteur.options[SelectIndex].value,etabSup.selected="SELECTED",etabSup.innerHTML=selecteur.options[SelectIndex].innerHTML,listeEtab.appendChild(etabSup),etabSup.focus()}}
function remove2List(a,c){listeEtab=dojo.byId(a);c!=null&&(listeEtab2=dojo.byId(c));SelectIndex=listeEtab.selectedIndex;if(SelectIndex!=-1){nbrEtabChoisi=listeEtab.length;for(i=0;i<nbrEtabChoisi;)listeEtab.options[i].selected&&(c!=""&&c!=null&&listeEtab2.removeChild(listeEtab2.options[i]),listeEtab.removeChild(listeEtab.options[i]),nbrEtabChoisi--,i--),i++}}function select_by_value(a,c){for(var d=0;d<a.length;d++)if(a.options[d].value==c)a.selectedIndex=d}
function checkboxes2list(a,c,d){listeEtab=dojo.byId(d);listeEtab.selectedIndex=-1;dojo.forEach(dojo.query(".checkbox_domaine_recherche:checked"),function(a){a.checked=!1;SelectIndex=a.id.substring(c.length,a.id.length);if(SelectIndex!=""){nbrEtabChoisi=listeEtab.length;pasChoisi=!0;for(i=0;i<nbrEtabChoisi&&pasChoisi;){if(SelectIndex==listeEtab.options[i].value)pasChoisi=!1,etabSup=listeEtab.options[i],listeEtab.options[i].selected="SELECTED";i++}if(pasChoisi&&SelectIndex!="")etabSup=document.createElement("option"),
etabSup.value=SelectIndex,etabSup.selected="SELECTED",etabSup.innerHTML=a.value,listeEtab.appendChild(etabSup);etabSup.focus();dojo.animateProperty({node:etabSup,delay:0,duration:500,properties:{backgroundColor:{start:"#1E90FF",end:"white"},color:{start:"#1E90FF",end:"black"}}}).play()}})}
function filterCheckBoxesTree(a,c,d,b){var e=[],f=[];filterValue=a==null?"":a.value=="Saisie rapide"?"":a.value;if(filterValue!=""){filterValue=noaccent(filterValue);for(cat in d)for(key in d[cat])inputNode=dojo.byId(b+key),str2find=noaccent(d[cat][key].LABEL),str2find.search(RegExp(filterValue,"i"))!=-1?(e[cat]=!0,dojo.removeClass(inputNode.parentNode.parentNode,"cache"),dojo.removeClass(inputNode.parentNode,"cache")):(dojo.addClass(inputNode.parentNode.parentNode,"cache"),dojo.addClass(inputNode.parentNode,
"cache"),inputNode.checked=!1,f[cat]=!0);for(cat in f)if(catNode=dojo.byId(b+cat),catNode!=null)catNode=catNode.parentNode.parentNode,dojo.removeClass(catNode,"jstree-open"),dojo.addClass(catNode,"explorertree-closed"),dojo.addClass(catNode,"cache");for(cat in e)if(catNode=dojo.byId(b+cat),catNode!=null)catNode=catNode.parentNode.parentNode,dojo.removeClass(catNode,"explorertree-closed"),dojo.addClass(catNode,"jstree-open"),dojo.removeClass(catNode,"cache")}else dojo.forEach(dojo.query("#"+c+" > ul > li"),
function(a){dojo.removeClass(a,"jstree-open");dojo.addClass(a,"explorertree-closed")}),dojo.forEach(dojo.query("#"+c+" .devlop"),function(a){dojo.removeClass(a,"cache")}),dojo.forEach(dojo.query("#"+c+" li"),function(a){dojo.removeClass(a,"cache")}),dojo.forEach(dojo.query("#"+c+" label"),function(a){dojo.removeClass(a,"cache")})}
function noaccent(a){temp=a.replace(/[\u00e0\u00e2\u00e4]/gi,"a");temp=temp.replace(/[\u00e9\u00e8\u00ea\u00eb]/gi,"e");temp=temp.replace(/[\u00ee\u00ef]/gi,"i");temp=temp.replace(/[\u00f4\u00f6]/gi,"o");return temp=temp.replace(/[\u00f9\u00fb\u00fc]/gi,"u")}var selectlist_connections=[];
function showchecklist(a){function c(){dojo.disconnect(f)}function d(){f=dojo.connect(window.document.body,"onclick",b)}function b(){dojo.forEach(selectlist_connections,dojo.disconnect);selectlist_connections=[];maskDiv(e.id);dojo.disconnect(f)}var e=dojo.query("#"+a.id+" > .checklistdropdown")[0],f;selectlist_connections.length==0&&(selectlist_connections.push(dojo.connect(a,"onmouseleave",d)),selectlist_connections.push(dojo.connect(a,"onmouseenter",c)),showDiv(e))}
function HTMLentitiesdecode(a){a=a.replace(/&amp;/g,"&");a=a.replace(/&quot;/g,'"');a=a.replace(/&lt;/g,"<");a=a.replace(/&gt;/g,">");a=a.replace(/&cent;/g,"\u00a2");a=a.replace(/&pound;/g,"\u00a3");a=a.replace(/&euro;/g,"\u20ac");a=a.replace(/&yen;/g,"\u00a5");a=a.replace(/&deg;/g,"\u00b0");a=a.replace(/&OElig;/g,"\u00bc");a=a.replace(/&oelig;/g,"\u00bd");a=a.replace(/&Yuml;/g,"\u00be");a=a.replace(/&iexcl;/g,"\u00a1");a=a.replace(/&laquo;/g,"\u00ab");a=a.replace(/&raquo;/g,"\u00bb");a=a.replace(/&iquest;/g,
"\u00bf");a=a.replace(/&Agrave;/g,"\u00c0");a=a.replace(/&Aacute;/g,"\u00c1");a=a.replace(/&Acirc;/g,"\u00c2");a=a.replace(/&Atilde;/g,"\u00c3");a=a.replace(/&Auml;/g,"\u00c4");a=a.replace(/&Aring;/g,"\u00c5");a=a.replace(/&AElig;/g,"\u00c6");a=a.replace(/&Ccedil;/g,"\u00c7");a=a.replace(/&Egrave;/g,"\u00c8");a=a.replace(/&Eacute;/g,"\u00c9");a=a.replace(/&Ecirc;/g,"\u00ca");a=a.replace(/&Euml;/g,"\u00cb");a=a.replace(/&Igrave;/g,"\u00cc");a=a.replace(/&Iacute;/g,"\u00cd");a=a.replace(/&Icirc;/g,
"\u00ce");a=a.replace(/&Iuml;/g,"\u00cf");a=a.replace(/&ETH;/g,"\u00d0");a=a.replace(/&Ntilde;/g,"\u00d1");a=a.replace(/&Ograve;/g,"\u00d2");a=a.replace(/&Oacute;/g,"\u00d3");a=a.replace(/&Ocirc;/g,"\u00d4");a=a.replace(/&Otilde;/g,"\u00d5");a=a.replace(/&Ouml;/g,"\u00d6");a=a.replace(/&Oslash;/g,"\u00d8");a=a.replace(/&Ugrave;/g,"\u00d9");a=a.replace(/&Uacute;/g,"\u00da");a=a.replace(/&Ucirc;/g,"\u00db");a=a.replace(/&Uuml;/g,"\u00dc");a=a.replace(/&Yacute;/g,"\u00dd");a=a.replace(/&THORN;/g,"\u00de");
a=a.replace(/&szlig;/g,"\u00df");a=a.replace(/&agrave;/g,"\u00e0");a=a.replace(/&aacute;/g,"\u00e1");a=a.replace(/&acirc;/g,"\u00e2");a=a.replace(/&atilde;/g,"\u00e3");a=a.replace(/&auml;/g,"\u00e4");a=a.replace(/&aring;/g,"\u00e5");a=a.replace(/&aelig;/g,"\u00e6");a=a.replace(/&ccedil;/g,"\u00e7");a=a.replace(/&egrave;/g,"\u00e8");a=a.replace(/&eacute;/g,"\u00e9");a=a.replace(/&ecirc;/g,"\u00ea");a=a.replace(/&euml;/g,"\u00eb");a=a.replace(/&igrave;/g,"\u00ec");a=a.replace(/&iacute;/g,"\u00ed");
a=a.replace(/&icirc;/g,"\u00ee");a=a.replace(/&iuml;/g,"\u00ef");a=a.replace(/&eth;/g,"\u00f0");a=a.replace(/&ntilde;/g,"\u00f1");a=a.replace(/&ograve;/g,"\u00f2");a=a.replace(/&oacute;/g,"\u00f3");a=a.replace(/&ocirc;/g,"\u00f4");a=a.replace(/&otilde;/g,"\u00f5");a=a.replace(/&ouml;/g,"\u00f6");a=a.replace(/&oslash;/g,"\u00f8");a=a.replace(/&ugrave;/g,"\u00f9");a=a.replace(/&uacute;/g,"\u00fa");a=a.replace(/&ucirc;/g,"\u00fb");a=a.replace(/&uuml;/g,"\u00fc");a=a.replace(/&yacute;/g,"\u00fd");a=a.replace(/&thorn;/g,
"\u00fe");return a=a.replace(/&yuml;/g,"\u00ff")}function hidePanel(a){maskDiv("btthideCritere");mouseWaitingOn();dojo.require("dojo.fx");dojo.fx.wipeOut({node:a,duration:300}).play();mouseWaitingOff();showDiv("bttshowCritere")}function showPanel(a){maskDiv("bttshowCritere");mouseWaitingOn();dojo.require("dojo.fx");dojo.fx.wipeIn({node:a,duration:300}).play();mouseWaitingOff();showDiv("btthideCritere")}
function togglePanel(a,c,d,b,e,f,g,h){f==void 0&&(f="toggle_reduce");g==void 0&&(g="toggle_expand");h==void 0&&(h=!0);theNode=jQuery(a);BttNode=jQuery(c);mouseWaitingOn();dojo.require("dojo.fx");theNode.is(":visible")?(h?theNode.slideUp("fast"):theNode.hide(),BttNode.html(b),BttNode.addClass(f),BttNode.removeClass(g)):(h?theNode.slideDown("fast"):theNode.show(),BttNode.html(e),BttNode.addClass(g),BttNode.removeClass(f));dojo.removeClass(document.body,"waiting");mouseWaitingOff()}
function trim(a){return a.replace(/^\s+/g,"").replace(/\s+$/g,"")}function ltrim(a){return a.replace(/^\s+/g,"")}function rtrim(a){return a.replace(/\s+$/g,"")}function deleteNode(a){for(;a.hasChildNodes();)a.removeChild(a.lastChild)}function str_right(a,c){if(c<=0)return"";else if(c>String(a).length)return a;else{var d=String(a).length;return String(a).substring(d,d-c)}}var zoom=4,autocenter=!1,SHADOW_Z_INDEX=10,MARKER_Z_INDEX=11,DIAMETER=200,map,layerTilesAtHome,layer,infocontrols,listMarker=[];
function initPos(a,c){dataArray=dojo.fromJson(c);for(idData in dataArray){data=null;data=dataArray[idData];if(dataArray!=null){if(dataArray.zoom!=void 0)zoom=dataArray.zoom;if(dataArray.autocenter!=void 0)autocenter=dataArray.autocenter}data[0]!=void 0?(lng=data[0].lng,lat=data[0].lat,name=data.nomorga,ville=data.ville,HTML=data.HTML,countryName=data.countryName,listMarker.push({lng:parseFloat(lng),lat:parseFloat(lat),name:name,ville:ville,countryName:countryName,HTML:HTML})):data.ville!=void 0&&
console.debug(data.ville+" not found.")}for(idMarker in listMarker)for(idMarkerAns in listMarker)listMarker[idMarker].lng==listMarker[idMarkerAns].lng&&listMarker[idMarker].lat==listMarker[idMarkerAns].lat&&idMarkerAns!=idMarker&&(listMarker[idMarkerAns].lng+=0.01,listMarker[idMarkerAns].lat+=0.01);layer=mapdrawFeatures();if(a!=null){if(a.zoom!=void 0)zoom=a.zoom;if(a.autocenter!=void 0)autocenter=a.autocenter}autocenter==!0?map.zoomToExtent(layer.getDataExtent()):(centrelon=lng,centrelat=lat,lonLat=
(new OpenLayers.LonLat(centrelon,centrelat)).transform(new OpenLayers.Projection("EPSG:4326"),map.getProjectionObject()),map.setCenter(lonLat,zoom))}
function mapinit(a,c,d){controlList=[];a==!0&&(controlList.push(new OpenLayers.Control.PanZoom({zoomWorldIcon:!1})),controlList.push(new OpenLayers.Control.Navigation({zoomWheelEnabled:!1})));map=new OpenLayers.Map(c,{controls:controlList,maxResolution:156543.0399,numZoomLevels:19,units:"m",projection:new OpenLayers.Projection("EPSG:4326"),displayProjection:new OpenLayers.Projection("EPSG:4326")});layerTilesAtHome=new OpenLayers.Layer.OSM.CycleMap("Carte");layerTilesAtHome.buffer=0;if(IE6||IE7||IE8)layerTilesAtHome.url[0]=
"/index/index/openstreetmap-tiles/mirror/a/z/${z}/x/${x}/y/${y}",layerTilesAtHome.url[1]="/index/index/openstreetmap-tiles/mirror/b/z/${z}/x/${x}/y/${y}",layerTilesAtHome.url[2]="/index/index/openstreetmap-tiles/mirror/c/z/${z}/x/${x}/y/${y}";IE6?a=new OpenLayers.StyleMap(OpenLayers.Util.applyDefaults({fillColor:"#E88A1B",fillOpacity:1,strokeColor:"gray",graphicName:"triangle",rotation:180,pointRadius:5},OpenLayers.Feature.Vector.style["default"])):(markerGraphic=d==void 0?"/scripts/osm/img/marker.png":
"/scripts/osm/img/"+d,a=new OpenLayers.StyleMap({externalGraphic:markerGraphic,backgroundGraphic:"/scripts/osm/img/marker_shadow.png",graphicWidth:16,graphicHeight:16,backgroundXOffset:0,backgroundYOffset:-7,graphicZIndex:MARKER_Z_INDEX,backgroundGraphicZIndex:SHADOW_Z_INDEX,pointRadius:10}));layer=new OpenLayers.Layer.Vector("Centre de recherche",{styleMap:a,isBaseLayer:!1,rendererOptions:{yOrdering:!0}});map.addLayers([layerTilesAtHome,layer]);map.addControl(new OpenLayers.Control.LayerSwitcher);
selectControl=new OpenLayers.Control.SelectFeature([layer],{clickout:!1,toggle:!0,multiple:!1,hover:!1,toggleKey:"ctrlKey",multipleKey:"shiftKey"});map.addControl(selectControl);selectControl.activate();layer.events.on({featureselected:function(a){if(a.feature.isOpen!=!0)mapshowInfo(a.feature),selectControl.unselect(a.feature),a.feature.isOpen=!0}})}
function mapcenterMap(){lonMoy=latMoy=0;for(idMarker in listMarker)marker=listMarker[idMarker],isNaN(marker.lat)||(latMoy+=marker.lat,lonMoy+=marker.lng);lonMoy/=listMarker.length;latMoy/=listMarker.length;lonLatMoy=(new OpenLayers.LonLat(lonMoy,latMoy)).transform(new OpenLayers.Projection("EPSG:4326"),map.getProjectionObject());map.setCenter(lonLatMoy,zoom)}
function mapdrawFeatures(){layer.removeFeatures(layer.features);var a=[];for(idMarker in listMarker)marker=listMarker[idMarker],newfeature=new OpenLayers.Feature.Vector((new OpenLayers.Geometry.Point(marker.lng,marker.lat)).transform(new OpenLayers.Projection("EPSG:4326"),map.getProjectionObject())),newfeature.text2affich=marker.name+"<br/>"+marker.ville,marker.ville!=""&&(newfeature.text2affich+="&nbsp;"),newfeature.text2affich+=marker.countryName,marker.HTML!=null&&(newfeature.text2affich+="<br/>"+
marker.HTML),a.push(newfeature);layer.addFeatures(a);return layer}function mapshowInfo(a){lonLat=new OpenLayers.LonLat(a.geometry.x,a.geometry.y);framepopup=new OpenLayers.Popup.FramedCloud("framecloud"+a.id,lonLat,null,a.text2affich,null,!0,mapclosingPopup);framepopup.markerClicked=a;map.addPopup(framepopup)}function clientMailExpernova(a){location.href="mailto:"+a+String.fromCharCode(64)+"expernova.com"}function mapclosingPopup(){this.markerClicked.isOpen=!1;this.hide()}
function estVisible(a){for(var c=0,d=0,b=0,e=0,f=0,g=0,h=0,j=0,g=a.offsetParent,k=!1,l=!1,m=!1,n=!1,c=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft,d=window.pageXOffset+window.innerWidth||document.documentElement.scrollLeft+document.documentElement.clientWidth||document.body.scrollLeft+document.body.clientWidth,b=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop,e=window.pageYOffset+window.innerHeight||document.documentElement.scrollTop+
document.documentElement.clientHeight||document.body.scrollTop+document.body.clientHeight,f=a.offsetLeft,h=a.offsetTop;g;)f+=g.offsetLeft,h+=g.offsetTop,g=g.offsetParent;g=f+a.offsetWidth;j=h+a.offsetHeight;c<=f&&d>=g?l=!0:d<f||c>g||(n=!0);b<=h&&e>=j?k=!0:e<h||b>j||(m=!0);return l&&k?!0:l&&m?!1:k&&n?!0:!1}function EncodeQueryData(a){var c=[],d;for(d in a)c.push(encodeURIComponent(d)+"="+encodeURIComponent(a[d]));return c.join("&")}
function centerCadrebyHeight(a){cdrParentHeight=jQuery("#"+a).parent().height();cdrHeight=jQuery("#"+a).height();cdrHeight!=0?(cdrMargin=(cdrParentHeight-cdrHeight)/2,jQuery("#"+a).css("margin-top",cdrMargin+"px")):setTimeout('centerCadrebyHeight("'+a+'")',200)}function clickbox(a){allchecks=a.parentNode.parentNode;dojo.query("input",allchecks).forEach(function(c){c.checked=a.checked})}
function clickCheckbox(a,c){if(a!=null)var d=a.checked;else{listcheckboxesBool=jQuery("#"+c+" input:checkbox").map(function(){return this.checked});for(var d=!0,b=0;b<=listcheckboxesBool.length-1;b++)d=d&&listcheckboxesBool[b];d=!d}jQuery("#"+c+" input").each(function(){this.checked=d})}function pluriel(a){return a>1?"s":""};

