function addLoadEvent(func) { 
	var oldonload = window.onload;
	  if (typeof window.onload != 'function') {
	    window.onload = func;
	  } else {
	    window.onload = function() {
	      if (oldonload) {//avoid a runtime error in IE 7
	        oldonload();
	      }
	      func();
	    }
	  }
}

var RC_Ajax_TotalSend=0
var RC_Ajax_TotalReceived=0

function RC_Ajax(langue){
	this.myProxy="/" + "communsGen" + "/" + "tools" + "/" + "proxy" + "." + "asp" +"?"+  "URL" + "="
	this.ajax_Async=true;
	this.ajax_RequestMethod="GET"; // GET / POST
	this.ajax_MimeType="text/plain";
	this.ajax_ParamsPOST=null;
	//alert("this.ajax_ParamsPOST="+this.ajax_ParamsPOST)
	if (typeof(langue)=="undefined")langue="fr"
	switch(langue.toLowerCase()){
		case "us" :
		case "gb" :
		case "uk" :
			this.ajax_LoadingMessage = "<span style='text-align:center;width:100%;height:100%;'><img src='/communsgen/images/wait.gif' /> Loading...</span>";
			this.ajax_ErrorMessage = "Problem retrieving data";
			break;
		case "es" :
			this.ajax_LoadingMessage = "<span style='text-align:center;width:100%;height:100%;'><img src='/communsgen/images/wait.gif' /> Cargamento...</span>";
			this.ajax_ErrorMessage = "Problema que recupera datos";
			break;					
		default:
			this.ajax_LoadingMessage = "<span style='text-align:center;width:100%;height:100%;'><img src='/communsgen/images/wait.gif' /> Chargement...</span>";
			this.ajax_ErrorMessage = "Problème pour récupérer les infos";
			break;
	}
	this.ajax_LoadingMessageObject=null ; // Si on a besoin d'un DIV ou SPAN particulier a remplir pour indiquer l'etat des transferts
	this.ajax_ReadyMessage = null;
	// function a appeler lors du click
	// exemple <a href="javascript:MonAjax=new RC_Ajax(); MonAjax.getURLOnOff('search.asp' , 'MonSpanID');">Lien</a>
	// ca remplira <span ID='MonSpanID'></span>
	// avec Contenu de la page search.asp
	
	
	this.TotalClear=function ()
	{
		RC_Ajax_TotalSend=0;
		RC_Ajax_TotalReceived=0;
	}
	this.ajax_createRequestObject=function ()
	{
		var ro;
		try {
			ro=new XMLHttpRequest();
			if (ro.overrideMimeType)
			{
				ro.overrideMimeType(this.ajax_MimeType); // "text/javascript" "text/xml" "text/plain" "text/html" 
			}
			return ro;
		} catch(e) {	
			try {
				var ro = new ActiveXObject("Msxml2.XMLHTTP");
			} catch (e) {
				try {
					var ro = new ActiveXObject("Microsoft.XMLHTTP");
				} catch(e) {
					return false;
				}
			}
		}
		return ro;
	}	
	
	this.getURLOnOff=function (TheURL , ID) {
		
		if(document.getElementById(ID).innerHTML == "")
		{
			//alert("1111111111")
			this.getURL(TheURL , ID) ;
			document.getElementById(ID).style.visibility ="visible";
		}else{
			//alert("222222222")
			document.getElementById(ID).innerHTML = "";
			document.getElementById(ID).style.visibility="hidden";
		}
	}
	
	this.getURL = function (TheURL , ID , options) {
		
		
		if(typeof options != 'undefined') { this.options = options; } else { this.options = {}; }
		if(this.options.onLoad) { this.onLoad = this.options.onLoad; }
		
		if(this.options.callBackFunction) { this.callBackFunction = this.options.callBackFunction; }
		
		if(this.options.onLoadError) { this.onLoadError = this.options.onLoadError; }
		
		
		
		var ajax_http=this.ajax_createRequestObject();
		
		//document.getElementById(ID).innerHTML = this.ajax_LoadingMessage;
		
		if(this.ajax_LoadingMessageObject!=null){
				document.getElementById(this.ajax_LoadingMessageObject).innerHTML = this.ajax_LoadingMessage
		}else{
				document.getElementById(ID).innerHTML = this.ajax_LoadingMessage
		}
		/*
		if(this.ajax_RequestMethod.toLowerCase()=="get"){
			ajax_http.setRequestHeader('Content-Type', 'text/xml');
		}else{
			ajax_http.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
		}
		*/
		ajax_http.open(this.ajax_RequestMethod, TheURL, this.ajax_Async)
		
		
		if(this.ajax_ParamsPOST != null && this.ajax_RequestMethod=="POST"){
			ajax_http.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
			ajax_http.setRequestHeader("Content-length", this.ajax_ParamsPOST.length);
			ajax_http.setRequestHeader("Connection", "close");
		}
		
		RC_Ajax_TotalSend++ ;
		//status=TheURL
		var self=this
		ajax_http.onreadystatechange = function(){
		    if(ajax_http.readyState==4){
		    	RC_Ajax_TotalReceived++
				if (( ajax_http.status>=200 && ajax_http.status<300) || ajax_http.status==100){
					
					if(self.ajax_LoadingMessageObject!=null){
							if(self.ajax_ReadyMessage!=null){
								document.getElementById(self.ajax_LoadingMessageObject).innerHTML = self.ajax_ReadyMessage
							}else{
								document.getElementById(self.ajax_LoadingMessageObject).innerHTML = ""
							}
					}
					try{
						
						document.getElementById(ID).innerHTML=ajax_http.responseText.toString();
						if(self.onLoad) {
							window.setTimeout(self.onLoad, 1 );
						}
						if(self.callBackFunction) {
							window.setTimeout(self.callBackFunction, 1 );
						}
						
						
						
						// Attention pas de <form> dans le HTML recu sur IE !!
					}
					catch(e){
						//marche pas ici //
						//self.ajax_ErrorMessage=ajax_http.responseText
						//alert(ajax_http.responseText.toString())
						//alert(document.getElementById(ID).innerHTML)
						// Attention pas de <form> dans le HTML recu sur IE !!
						self.showErrorHTTPMessage(ID , "(err 3 - Please no <form> in response !!)")
						if(self.onLoadError) {
							window.setTimeout(self.onLoadError, 1 );
						}
					}
					
				}else{
					
					self.showErrorHTTPMessage(ID , "(err 4 -  HTTP Status : "+ ajax_http.status +".)")
					if(self.onLoadError) {
						window.setTimeout(self.onLoadError, 1 );
					}
				}
		    }				
		};
		
		ajax_http.send(this.ajax_ParamsPOST);
	}
	
	
	
	this.showErrorHTTPMessage=function(ID, moreInfo){
		if(this.ajax_ErrorMessage){
	    	if(this.ajax_LoadingMessageObject!=null){
				document.getElementById(this.ajax_LoadingMessageObject).innerHTML = this.ajax_ErrorMessage + moreInfo
			}else{
				if(ID){
						document.getElementById(ID).innerHTML = this.ajax_ErrorMessage + moreInfo
				}
			}
			status=this.ajax_ErrorMessage
		}
	}
	
	//execute le JS recu
	this.getURLJS = function (TheURL) 
	{
			var ajax_http=this.ajax_createRequestObject();
			if(this.ajax_LoadingMessageObject!=null)document.getElementById(this.ajax_LoadingMessageObject).innerHTML = this.ajax_LoadingMessage
			/*
			if(this.ajax_RequestMethod.toLowerCase()=="get"){
				ajax_http.setRequestHeader('Content-Type', 'text/xml');
			}else{
				ajax_http.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
			}
			*/
			ajax_http.open(this.ajax_RequestMethod, TheURL, this.ajax_Async)
			
			if(this.ajax_ParamsPOST != null && this.ajax_RequestMethod=="POST"){
				ajax_http.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
				ajax_http.setRequestHeader("Content-length", this.ajax_ParamsPOST.length);
				ajax_http.setRequestHeader("Connection", "close");
			}
			
			//window.open(TheURL)
			var self=this
			if(this.ajax_Async){
				RC_Ajax_TotalSend++;
				ajax_http.onreadystatechange = function(){
						
					    if(ajax_http.readyState == 4)
					    {
					    	RC_Ajax_TotalReceived++;
					        if (ajax_http.status==200 || ajax_http.status==100)
							    {
							    	try{
							    		eval(ajax_http.responseText); 
							    	}
							    	catch(e){
							    		
							    		self.showErrorHTTPMessage()
							    	}
							    }
							  else
							    {
							    	
							    	self.showErrorHTTPMessage(self.ajax_LoadingMessageObject , "(err 1)" )
							    }
					    }				
				};
			}
			ajax_http.send(this.ajax_ParamsPOST);
			
			if(!this.ajax_Async){
					if (ajax_http.status==200 || ajax_http.status==100){
						eval(ajax_http.responseText);   
					}else{
						if(self.ajax_LoadingMessageObject){
							
							self.showErrorHTTPMessage(self.ajax_LoadingMessageObject , "(err 2)")
						}else{
							status=self.ajax_ErrorMessage
						}
					}
			}
	}	
	
	
	//pour lancer une fonction avec comme parametre les infos recu par l'URL indiqué
	this.getURLToFunction = function(url, callBackFunction){
		
		//doAjaxGet('http://blog.eurekaa.org/rss.php?blogId=1&profile=rss10', 'outputRss(xmlResponse / txtResponse)');
		//monAjax.getURLToFunction('http://infos.imagesenligne.com/consulter/ActualitesXML.asp?isActu=1&LangueID=1', function (txtResponse){outputRss1(txtResponse,"FluxRSSEvolutionIEL")} );
		
		
		if (typeof netscape != 'undefined' && typeof netscape.security != 'undefined') {
		//decommenter cette ligne pour tester le script en local
		//                netscape.security.PrivilegeManager.enablePrivilege('UniversalBrowserRead');
		        }
		 var xmlResponse = null;
		 var txtResponse = null;
		// createXmlHttpObject();
		
		var xmlhttp=this.ajax_createRequestObject();
		if(this.ajax_LoadingMessageObject!=null){
				
				document.getElementById(this.ajax_LoadingMessageObject).innerHTML = this.ajax_LoadingMessage
		}
		
		if( url.substring(0,4).toLowerCase()=="http")url=this.myProxy + escape(url)
		
		
		 xmlhttp.open(this.ajax_RequestMethod, url, this.ajax_Async ); // le troisième paramètre (true) indique que la requete est asynchrone : elle ne vas pas bloquer la page en cours
		 
		 
		 
		 if(this.ajax_ParamsPOST != null && this.ajax_RequestMethod=="POST"){
			xmlhttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
			xmlhttp.setRequestHeader("Content-length", this.ajax_ParamsPOST.length);
			xmlhttp.setRequestHeader("Connection", "close");
		 }
		
		 if (this.ajax_Async){
		 	 RC_Ajax_TotalSend++;
			 xmlhttp.onreadystatechange=function() { //on attache notre fonction de callback
			  if (xmlhttp.readyState==4) { // il y'a 4 etats differents pour xmlHttpObject l'etat 4 indique la fin de la requte
			  	RC_Ajax_TotalReceived++;
			    if (xmlhttp.status == 200)  //le code de statut 200 indique que tout s'est bien passé 
			    {
			      txtResponse = xmlhttp.responseText;  //ces deux variables peuvent etre apellé par la fonction
			      xmlResponse = xmlhttp.responseXML;   //  de callback
			       
			      //eval(callBackFunction); //execution de notre fonction de callback
			      
			      callBackFunction(txtResponse)
			      
			    }    
			  }
			 }
			 xmlhttp.send(this.ajax_ParamsPOST);
		 }else{
		 	xmlhttp.send(this.ajax_ParamsPOST);
		 	  if (xmlhttp.readyState==4) { // il y'a 4 etats differents pour xmlHttpObject l'etat 4 indique la fin de la requte
			    if (xmlhttp.status == 200)  //le code de statut 200 indique que tout s'est bien passé 
			    {
			      txtResponse = xmlhttp.responseText;  //ces deux variables peuvent etre apellé par la fonction
			      xmlResponse = xmlhttp.responseXML;   //  de callback
			       
			      //eval(callBackFunction); //execution de notre fonction de callback
			      
			      callBackFunction(txtResponse)
			      
			    }    
			  }
		 
		 }
		 
	}
	 
	this.ajax_transform=function (xml, xsl, ID) { 
		try { /*  Navigateur basé sur Gecko. */ 
			if (window.XSLTProcessor) { 
				var fragment; 
	            var xsltProcessor = new XSLTProcessor(); 
				
				xsltProcessor.importStylesheet(xsl); 
	            fragment = xsltProcessor.transformToFragment(xml, document); 
	 
	            var target = document.getElementById(ID); 
	            target.appendChild(fragment); 
	            document.appendChild(target); 
	        }  
			else if (window.ActiveXObject) { /* ActiveX pour Internet Explorer. */ 
	            var target = document.getElementById(ID); 
				
				var xml = new ActiveXObject("Microsoft.XMLDOM") 
				xml.async = false 
				xml.load("xmldemo.xml") 
				       
	            if (typeof xml == "string") xml = XML.load(xml);
		    	this.xml = xml;
		    	
		    	if (typeof xsl == "string") xsl = XML.load(xsl);
		    	this.xsl = xsl;
		    	
	            target.innerHTML = xml.transformNode(xsl); 
	        } 
	 
	    }  
		 
		catch (e) { 
	        return e; 
	    } 
	}
	
	//http://forum.alsacreations.com/topic.php?fid=3&tid=21107
	
	 this.loadXML=function (url)
	  {
	    var xmlDoc;
	    /* chargement du fichier XML */
	    try {
	      // navigateur basé sur Gecko
	      if (document.implementation && document.implementation.createDocument)
	      {
	        xmlDoc = document.implementation.createDocument('', '', null);
	        xmlDoc.load(url);
	      // ActiveX pour Internet Explorer
	      } else if (window.ActiveXObject) {
	        try {
	          xmlDoc = new ActiveXObject('Msxml2.XMLDOM');
	        } catch (e) {
	          xmlDoc = new ActiveXObject('Microsoft.XMLDOM');
	        }
	        xmlDoc.async = false;
	        xmlDoc.load(url);
	      // à l'aide de lobjet XMLHTTPRequest
	      } else if (window.XMLHttpRequest) {
	        xmlDoc = new XMLHttpRequest();
	        xmlDoc.overrideMimeType('text/xml');
	        xmlDoc.open('GET', url, false);
	        xmlDoc.send(null);
	        if (this.xmlDoc.readyState == 4) xmlDoc = xmlDoc.responseXML;
	      }
	    } catch (e) {
	      return e;
	    }
	    return xmlDoc;
	  }
	
	  this.transform=function(ID)
	  {  
	     var xml = loadXML(artisteURL);
	     var xsl = loadXML(paroleURL);
	
	    try {
	      // navigateur basé sur Gecko
	      if (window.XSLTProcessor)
	      {
	        var fragment;
	        var xsltProcessor = new XSLTProcessor();
	
	        xsltProcessor.importStylesheet(xsl);
	        fragment = xsltProcessor.transformToFragment(xml, document);
	        var target = document.getElementById(ID);            
	        target.appendChild(fragment);
	        document.appendChild(target);
	
	      // ActiveX pour Internet Explorer
	      } else if (window.ActiveXObject) {
	        var target = document.getElementById(ID);
	        target.innerHTML = xml.transformNode(xsl);
	      }
	
	    } catch (e) {
	      return e;
	    }
	  }
	
	  var artisteURL = 'dyn.php';
	  var paroleURL = 'xsldyn.xsl';
	
	
	this.XML=function ()	{
		/**
		 * This XML.Transformer class encapsulates an XSL stylesheet.
		 * If the stylesheet parameter is a URL, we load it.
		 * Otherwise, we assume it is an appropriate DOM Document.
		 */
		
		XML.Transformer = function(stylesheet) {
		    // Load the stylesheet if necessary.
		    if (typeof stylesheet == "string") stylesheet = XML.load(stylesheet);
		    this.stylesheet = stylesheet;
		    // In Mozilla-based browsers, create an XSLTProcessor object and
		    // tell it about the stylesheet.
		    if (typeof XSLTProcessor != "undefined") {
		        this.processor = new XSLTProcessor();
		        this.processor.importStylesheet(this.stylesheet);
		    }
		};
		/**
		 * This is the transform() method of the XML.Transformer class.
		 * It transforms the specified xml node using the encapsulated stylesheet.
		 * The results of the transformation are assumed to be HTML and are used to
		 * replace the content of the specified element.
		 */
		XML.Transformer.prototype.transform = function(node, element) {
		    // If element is specified by Id, look it up.
		    if (typeof element == "string") element = document.getElementById(element);
		    if (this.processor) {
		        // If we've created an XSLTProcessor (i.e., we're in Mozilla) use it.
		        // Transform the node into a DOM DocumentFragment.
		        var fragment = this.processor.transformToFragment(node, document);
		        // Erase the existing content of element.
		        element.innerHTML = "";
		        // And insert the transformed nodes.
		        element.appendChild(fragment);
		    }
		    else if ("transformNode" in node) {
		        // If the node has a transformNode() function (in IE), use that.
		        // Note that transformNode() returns a string.
		        element.innerHTML = node.transformNode(this.stylesheet);
		    }
		    else {
		        // Otherwise, we're out of luck.
		        throw "XSLT is not supported in this browser";
		    }
		};
		/**
		 * This is an XSLT utility function that is useful when a stylesheet is
		 * used only once.
		 */
		XML.transform = function(xmldoc, stylesheet, element) {
		    var transformer = new XML.Transformer(stylesheet);
		    transformer.transform(xmldoc, element);
		}
	}
	
	
	this.xml_ParseXMLFromString = function ( text ){
		// code for IE
		if (window.ActiveXObject)
		  {
		  var doc=new ActiveXObject("Microsoft.XMLDOM");
		  doc.async="false";
		  doc.loadXML(text);
		  }
		// code for Mozilla, Firefox, Opera, etc.
		else
		  {
		  var parser=new DOMParser();
		  var doc=parser.parseFromString(text,"text/xml");
		  }
		return doc;
	}
	
}



function SecurePassM(form , nomChampPass , nomChampPassFinal ){
	//Ancien systeme
	
	this.bCrypted=false
	this.Obj_nomChampPass		= eval ("document." + form.name + "."+ nomChampPass )
	this.Obj_nomChampPassFinal	= eval ("document." + form.name + "."+ nomChampPassFinal )

	MonAjax=new RC_Ajax(); 
	MonAjax.ajax_Async=false
	mySelf=this
	try{
		if (this.Obj_nomChampPass.value !="" && this.Obj_nomChampPassFinal ){
			MonAjax.getURLToFunction("/CommunsGen/Tools/Crypte/SecurePassGetKey.asp?rn="+ (new Date()).getTime() , function(txtResponse){  
					var SecurePassKey=txtResponse;
					var tempoPassFinal=hex_md5(SecurePassKey +"@"+ mySelf.Obj_nomChampPass.value ).toUpperCase();
					//alert(tempoPassFinal)
					mySelf.Obj_nomChampPass.value=""
					mySelf.Obj_nomChampPassFinal.value=tempoPassFinal
					SecurePassKey="";
					mySelf.bCrypted=true;
				}   
			);
		}else{
			mySelf.Obj_nomChampPass.value="";
			mySelf.Obj_nomChampPassFinal.value="";
		}
	} catch(e) {
		mySelf.Obj_nomChampPass.value="";
		mySelf.Obj_nomChampPassFinal.value="";
		return false;
	}
	//this.Obj_nomChampPass.value="";
	return true
}


function SecurePass(form , nomChampPass , nomChampPassFinal ){
	
	return SecurePassV2(form , nomChampPass , nomChampPassFinal )
	
	this.bCrypted=false
	this.Obj_nomChampPass		= eval ("document." + form.name + "."+ nomChampPass )
	this.Obj_nomChampPassFinal	= eval ("document." + form.name + "."+ nomChampPassFinal )

	MonAjax=new RC_Ajax(); 
	MonAjax.ajax_Async=false
	mySelf=this
	try{
		if (this.Obj_nomChampPass.value !="" && this.Obj_nomChampPassFinal ){
			MonAjax.getURLToFunction("/CommunsGen/Tools/Crypte/SecurePassGetKey.asp?rn="+ (new Date()).getTime() , function(txtResponse){  
					var SecurePassKey=txtResponse;
					var tempoPassFinal=hex_md5(SecurePassKey +"@"+ mySelf.Obj_nomChampPass.value ).toUpperCase();
					
					mySelf.Obj_nomChampPass.value=""
					mySelf.Obj_nomChampPassFinal.value=tempoPassFinal
					SecurePassKey="";
					mySelf.bCrypted=true;
				}   
			);
		}else{
			mySelf.Obj_nomChampPass.value="";
			mySelf.Obj_nomChampPassFinal.value="";
		}
	} catch(e) {
		mySelf.Obj_nomChampPass.value="";
		mySelf.Obj_nomChampPassFinal.value="";
		return false;
	}
	//this.Obj_nomChampPass.value="";
	return true
}




function SecurePassV2(form , nomChampPass , nomChampPassFinal ){
	//Cryptage du password dans un nouveau champ
	this.bCrypted=false
	this.Obj_nomChampPass		= eval ("document." + form.name + "."+ nomChampPass )
	this.Obj_nomChampPassFinal	= eval ("document." + form.name + "."+ nomChampPassFinal )

	MonAjax=new RC_Ajax(); 
	MonAjax.ajax_Async=false
	mySelf=this
	try{
		if (this.Obj_nomChampPass.value !="" && this.Obj_nomChampPassFinal ){
			MonAjax.getURLToFunction("/CommunsGen/Tools/Crypte/SecurePassGetKey.asp?rn="+ (new Date()).getTime() , function(txtResponse){  
					var SecurePassKey=txtResponse;
					
					
					var tempoPassTransform=hex_sha1( mySelf.Obj_nomChampPass.value ).toUpperCase();
					
					mySelf.Obj_nomChampPass.value=""
					
					var tempoPassFinal=hex_md5(SecurePassKey +"@"+ tempoPassTransform ).toUpperCase();
					mySelf.Obj_nomChampPassFinal.value="x"+ tempoPassFinal +"x"
					
					
					//var infosAutre="hex_sha1=" + tempoPassTransform +"-- SecurePassKey="+SecurePassKey +"--PassFinal="+ tempoPassFinal
					
					
					SecurePassKey="";
					mySelf.bCrypted=true;
					
					//mySelf.Obj_nomChampPassFinal.value="x"+ infosAutre +"x"
				}   
			);
		}else{
			mySelf.Obj_nomChampPass.value="";
			mySelf.Obj_nomChampPassFinal.value="";
			
		}
	} catch(err) {
		alert("Error2" )
		/*
		alert("Error2 :  Error name: " + err.name
				+ ". Error description: " + err.description
				+ ". Error number: " + err.number
				+ ". Error message: " + err.message 
				+ ". Error line: " + err.line

			)
		*/
		mySelf.Obj_nomChampPass.value="";
		mySelf.Obj_nomChampPassFinal.value="";
		return false;
	}
	//this.Obj_nomChampPass.value="";
	return true
}

function SecurePassV2AdmForm(form , nomChampPass , nomChampPassFinal , cle ){
	//try{
		var nomChampPassValue		= eval ("document." + form.name + "."+ nomChampPass +".value" )
		
		
		
		
		if(nomChampPassValue!='xxxxxxxxxxxx' ){
			if(form.Password_Confirm) form.Password_Confirm.value='';
			if(form.Inscr_passwordVerif) form.Inscr_passwordVerif.value='';
			return SecureChangePassV2(form , nomChampPass , nomChampPassFinal , cle );
		}else{
			return true
		}
	/*
	}catch(err) {
		
		alert("Error2 : RC_Ajax/SecurePassV2AdmForm" 
				+ " \nError name: " + err.name
				+ ". \nError description: " + err.description
				+ ". \nError number: " + err.number
				+ ". \nError message: " + err.message 
				+ ". \nError line: " + err.line

			)
		return false;
	}
	*/
}


function SecureChangePassV2(form , nomChampPass , nomChampPassFinal , cle ){
	//Cryptage du NOUVEAU password dans un nouveau champ
	this.bCrypted=false
	this.Obj_nomChampPass		= eval ("document." + form.name + "."+ nomChampPass )
	this.Obj_nomChampPassFinal	= eval ("document." + form.name + "."+ nomChampPassFinal )
	this.Obj_nomChampPass_Confirm   = eval ("document." + form.name + "."+ nomChampPass +"_Confirm") 
	try{
		if(!this.Obj_nomChampPass_Confirm)this.Obj_nomChampPass_Confirm   = form.Inscr_passwordVerif
	}catch(err){
		
	}
	
	MonAjax=new RC_Ajax(); 
	MonAjax.ajax_Async=false
	mySelf=this
	try{
		if (this.Obj_nomChampPass.value !="" && this.Obj_nomChampPassFinal ){
			MonAjax.getURLToFunction("/CommunsGen/Tools/Crypte/SecurePassGetKey.asp?rn="+ (new Date()).getTime() , function(txtResponse){  
					var SecurePassKey=txtResponse;
					var tempoPassTransform=hex_sha1( SecurePassKey +"-"+ hex_sha1(cle).toUpperCase()  ).toUpperCase();
					var tempoPassAESFinal = AESEncryptCtr( this.Obj_nomChampPass.value +'@'+ SecurePassKey , tempoPassTransform , 256)
					mySelf.Obj_nomChampPass.value=""
					mySelf.Obj_nomChampPass_Confirm.value=""
					mySelf.Obj_nomChampPassFinal.value= tempoPassAESFinal 
					SecurePassKey="";
					mySelf.bCrypted=true;
				}   
			);
		}else{
			mySelf.Obj_nomChampPass.value="";
			mySelf.Obj_nomChampPassFinal.value="";
			alert("Erreur(1) \nRéssayez SVP !\n\nError(1) \nPlease retry !")
			return false;
		}
	} catch(err) {
		mySelf.Obj_nomChampPass.value="";
		mySelf.Obj_nomChampPassFinal.value="";
		alert("Erreur(2) \nRéssayez SVP !\n\nError(2) \nPlease retry !")
		/*
		alert("Error2 :  \nError name: " + err.name
				+ ". \nError description: " + err.description
				+ ". \nError number: " + err.number
				+ ". \nError message: " + err.message 
				+ ". \nError line: " + err.line

			)
		*/ 
		return false;
	}
	//this.Obj_nomChampPass.value="";
	return true
}





/*
 * (c)2006 Jesse Skinner/Dean Edwards/Matthias Miller/John Resig
 * Special thanks to Dan Webb's domready.js Prototype extension
 * and Simon Willison's addLoadEvent
 *
 * For more info, see:
 * http://www.thefutureoftheweb.com/blog/adddomloadevent
 * http://dean.edwards.name/weblog/2006/06/again/
 * http://www.vivabit.com/bollocks/2006/06/21/a-dom-ready-extension-for-prototype
 * http://simon.incutio.com/archive/2004/05/26/addLoadEvent
 * 
 *
 * To use: call addDOMLoadEvent one or more times with functions, ie:
 *
 *    function something() {
 *       // do something
 *    }
 *    addDOMLoadEvent(something);
 *
 *    addDOMLoadEvent(function() {
 *        // do other stuff
 *    });
 *
 */
 
addDOMLoadEvent = (function(){
    // create event function stack
    var load_events = [],
        load_timer,
        script,
        done,
        exec,
        old_onload,
        init = function () {
            done = true;

            // kill the timer
            clearInterval(load_timer);

            // execute each function in the stack in the order they were added
            while (exec = load_events.shift())
                exec();

            if (script) script.onreadystatechange = '';
        };

    return function (func) {
        // if the init function was already ran, just run this function now and stop
        if (done) return func();

        if (!load_events[0]) {
            // for Mozilla/Opera9
            if (document.addEventListener)
                document.addEventListener("DOMContentLoaded", init, false);

            // for Internet Explorer
            /*@cc_on @*/
            /*@if (@_win32)
                document.write("<script id=__ie_onload defer src=//0><\/scr"+"ipt>");
                script = document.getElementById("__ie_onload");
                script.onreadystatechange = function() {
                    if (this.readyState == "complete")
                        init(); // call the onload handler
                };
            /*@end @*/

            // for Safari
            if (/WebKit/i.test(navigator.userAgent)) { // sniff
                load_timer = setInterval(function() {
                    if (/loaded|complete/.test(document.readyState))
                        init(); // call the onload handler
                }, 10);
            }

            // for other browsers set the window.onload, but also execute the old window.onload
            old_onload = window.onload;
            window.onload = function() {
                init();
                if (old_onload) old_onload();
            };
        }

        load_events.push(func);
    }
})();
