function MM_swapImgRestore() {
if (document.MM_swapImgData != null)
for (var i=0; i<(document.MM_swapImgData.length-1); i+=2)
document.MM_swapImgData[i].src = document.MM_swapImgData[i+1];}
function MM_preloadImages() {
if (document.images) {
var imgFiles = MM_preloadImages.arguments;
if (document.preloadArray==null) document.preloadArray = new Array();
var i = document.preloadArray.length;
with (document) for (var j=0; j<imgFiles.length; j++) if (imgFiles[j].charAt(0)!="#"){
preloadArray[i] = new Image;
preloadArray[i++].src = imgFiles[j];}}}
function MM_swapImage() {
var i,j=0,objStr,obj,swapArray=new Array,oldArray=document.MM_swapImgData;
for (i=0; i < (MM_swapImage.arguments.length-2); i+=3) {
objStr = MM_swapImage.arguments[(navigator.appName == 'Netscape')?i:i+1];
if ((objStr.indexOf('document.layers[')==0 && document.layers==null) ||
(objStr.indexOf('document.all[')   ==0 && document.all   ==null))
objStr = 'document'+objStr.substring(objStr.lastIndexOf('.'),objStr.length);
obj = document.getElementById(objStr);
if (obj != null) {
swapArray[j++] = obj;
swapArray[j++] = (oldArray==null || oldArray[j-1]!=obj)?obj.src:oldArray[j];
obj.src = MM_swapImage.arguments[i+2];}}
document.MM_swapImgData = swapArray;}
/* nifty.js */
function NiftyCheck(){
if(!document.getElementById || !document.createElement)
    return(false);
    
isXHTML=/html\:/.test(document.getElementsByTagName('body')[0].nodeName);
if(Array.prototype.push==null){Array.prototype.push=function(){
      this[this.length]=arguments[0]; return(this.length);}}
return(true);

}

function nifty2Rounded(selector,wich,bk,color,opt){
var i,prefixt,prefixb,cn="r",ecolor="",edges=false,eclass="",b=false,t=false;

if(color=="transparent"){
    cn=cn+"x";
    ecolor=bk;
    bk="transparent";
    }
else if(opt && opt.indexOf("border")>=0){
    var optar=opt.split(" ");
    for(i=0;i<optar.length;i++)
        if(optar[i].indexOf("#")>=0) ecolor=optar[i];
    if(ecolor=="") ecolor="#666";
    cn+="e";
    edges=true;
    }
else if(opt && opt.indexOf("smooth")>=0){
    cn+="a";
    ecolor=Mix(bk,color);
    }
if(opt && opt.indexOf("small")>=0) cn+="s";
prefixt=cn;
prefixb=cn;
if(wich.indexOf("all")>=0){t=true;b=true}
else if(wich.indexOf("top")>=0) t="true";
else if(wich.indexOf("tl")>=0){
    t="true";
    if(wich.indexOf("tr")<0) prefixt+="l";
    }
else if(wich.indexOf("tr")>=0){
    t="true";
    prefixt+="r";
    }
if(wich.indexOf("bottom")>=0) b=true;
else if(wich.indexOf("bl")>=0){
    b="true";
    if(wich.indexOf("br")<0) prefixb+="l";
    }
else if(wich.indexOf("br")>=0){
    b="true";
    prefixb+="r";
    }
var v=getElementsBySelector(selector);
var l=v.length;
for(i=0;i<l;i++){
    if(edges) nifty2AddBorder(v[i],ecolor);
    if(t) nifty2AddTop(v[i],bk,color,ecolor,prefixt);
    if(b) nifty2AddBottom(v[i],bk,color,ecolor,prefixb);
    }
}

function nifty2AddBorder(el,bc){
var i;
if(!el.passed){
    if(el.childNodes.length==1 && el.childNodes[0].nodeType==3){
        var t=el.firstChild.nodeValue;
        el.removeChild(el.lastChild);
        var d=CreateEl("span");
        d.style.display="block";
        d.appendChild(document.createTextNode(t));
        el.appendChild(d);
        }
    for(i=0;i<el.childNodes.length;i++){
        if(el.childNodes[i].nodeType==1){
            el.childNodes[i].style.borderLeft="1px solid "+bc;
            el.childNodes[i].style.borderRight="1px solid "+bc;
            }
        }
    }
el.passed=true;
}
    
function nifty2AddTop(el,bk,color,bc,cn){
var i,lim=4,d=CreateEl("b");

if(cn.indexOf("s")>=0) lim=2;
if(bc) d.className="artop";
else d.className="rtop";
d.style.backgroundColor=bk;
for(i=1;i<=lim;i++){
    var x=CreateEl("b");
    x.className=cn + i;
    x.style.backgroundColor=color;
    if(bc) x.style.borderColor=bc;
    d.appendChild(x);
    }
el.style.paddingTop=0;
el.insertBefore(d,el.firstChild);
}

function nifty2AddBottom(el,bk,color,bc,cn){
var i,lim=4,d=CreateEl("b");

if(cn.indexOf("s")>=0) lim=2;
if(bc) d.className="artop";
else d.className="rtop";
d.style.backgroundColor=bk;
for(i=lim;i>0;i--){
    var x=CreateEl("b");
    x.className=cn + i;
    x.style.backgroundColor=color;
    if(bc) x.style.borderColor=bc;
    d.appendChild(x);
    }
el.style.paddingBottom=0;
el.appendChild(d);
}

function CreateEl(x){
if(isXHTML) return(document.createElementNS('http://www.w3.org/1999/xhtml',x));
else return(document.createElement(x));
}

function getElementsBySelector(selector){
var i,selid="",selclass="",tag=selector,f,s=[],objlist=[];

if(selector.indexOf(" ")>0){  //descendant selector like "tag#id tag"
    s=selector.split(" ");
    var fs=s[0].split("#");
    if(fs.length==1) return(objlist);
    f=document.getElementById(fs[1]);
    if(f) return(f.getElementsByTagName(s[1]));
    return(objlist);
    }
if(selector.indexOf("#")>0){ //id selector like "tag#id"
    s=selector.split("#");
    tag=s[0];
    selid=s[1];
    }
if(selid!=""){
    f=document.getElementById(selid);
    if(f) objlist.push(f);
    return(objlist);
    }
if(selector.indexOf(".")>0){  //class selector like "tag.class"
    s=selector.split(".");
    tag=s[0];
    selclass=s[1];
    }
var v=document.getElementsByTagName(tag);  // tag selector like "tag"
if(selclass=="")
    return(v);
for(i=0;i<v.length;i++){
    if(v[i].className.indexOf(selclass)>=0){
        objlist.push(v[i]);
        }
    }
return(objlist);
}

function Mix(c1,c2){
var i,step1,step2,x,y,r=new Array(3);
if(c1.length==4)step1=1;
else step1=2;
if(c2.length==4) step2=1;
else step2=2;
for(i=0;i<3;i++){
    x=parseInt(c1.substr(1+step1*i,step1),16);
    if(step1==1) x=16*x+x;
    y=parseInt(c2.substr(1+step2*i,step2),16);
    if(step2==1) y=16*y+y;
    r[i]=Math.floor((x*50+y*50)/100);
    }
return("#"+r[0].toString(16)+r[1].toString(16)+r[2].toString(16));
} 
/* tip_search */
var s = new Array();
s[0]="Accueil^index.htm^0<div></br></div>^google maps cloudmade map composant delphi Fenêtre principale Web aide en ligne html xhtml chm pdf htmlhelp hlp winhelp ^0";
s[1]="Historique^historique.htm^0<div></br></div>^Gestion d'une base de donnéesPdf produit par Gestion d'une base de données Assistant rollover Assistant tableau rapide dernière version version news nouveautés historique ^0";
s[2]="Historique ancien^historique_ancien.htm^0<div></br></div>^^0";
s[3]="Licence^licence.htm^0<div></br></div>^Entreprise Licence ^0";
s[4]="Traduire Help&Web^traduire_help_web.htm^0<div></br></div>^traduire Assistant traduction Traduction ^0";
s[5]="Informations légales^informations_legales.htm^0<div></br></div>^^0";
s[6]="Visite guidée^visite_guidee.htm^0<div></br></div>^composant rss mot clef définition champ calculé multiformat Scripts Recherche/Remplacement Quelques fonctionnalités d'Help&Web Notes de bas de page Multilingues Multi-formats Mots clefs Gestion des définitions Contenu partagé Des boutons même en hlps Chercher/Remplacer Rechercher dans les rubriques GlossaryTerme en action Gérez vos définitions Protection hlp et html/htmlhelp Gestion d'une base de données Compilation conditionnelle Chercher-Remplacer Champs calculés De beaux boutons même en hlp fonctions fonctionnalités atout Visite guidée ^0";
s[7]="Composants^composants.htm^0<div></br></div>^script Composant Gestion d'une base de données Resume en action Gestion palette Propriétées d'un composant Les composants standards Bandeau supérieur de l'aide php paramètre miniature gabarit code javascript Composants ^0";
s[8]="Tutoriaux^tutoriaux.htm^0<div></br></div>^tutorial exemple aide tutoriaux ^0";
s[9]="Création d'un site^creation_d_un_site.htm^0<div></br></div>^tutorial Html-Layout Partage Css Edition Feuille de styles Assistant création de projet Propriétés html-layout Insertion html-layout Contenu partagé Page type du site ^0";
s[10]="Miniatures^miniatures.htm^0<div></br></div>^tutorial Css Image Miniature Composant ^0";
s[11]="Moteur de recherche^moteur_de_recherche.htm^0<div></br></div>^tutorial Composant Javascript Recherche Propriétés Search En-tête global du site Moteur de recherche ^0";
s[12]="HTMLoverlay^htmloverlay.htm^0<div></br></div>^tutorial Composant Zone spéciale Utiliser le composant HTMLOverlay source de la page utilisant un overlay Source de l'overlay Création d'un contenu partagé contenant l'overlay HTMLoverlay ^0";
s[13]="Intégrer javascript^integrer_javascript.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^tutorial Javascript Intégrer javascript ^0";
s[14]="Intégrer un lecteur MP3^integrer_un_lecteur_mp3.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^tutorial Utilisation de DewPlayer DewPlayer intégré à Help&Web MP3 Composant Intégrer un lecteur MP3 ^0";
s[15]="Effet d'ombrage^effet_d_ombrage.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^tutorial Css Composant Ombre Effet d'ombrage ^0";
s[16]="Dictionnaire Alexandria^dictionnaire_alexandria.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^tutorial Activer Alexandria sur l'ensemble du site Dictionnaire Composant Dictionnaire Alexandria ^0";
s[17]="Créer un projet multilingue^creer_un_projet_multilingue.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^tutorial traduction Sélection des langues à compiler Traduction des titres des rubriques Activation d'une langue Traduction des options Gestion des langues Multilingue langue Créer un projet multilingue ^0";
s[18]="Sauvegarde des projets^sauvegarde_des_projets.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^tutorial Gestion des restaurations Historique d'une rubrique Sauvegarde restaurer historique archive Stratégies de sauvegarde des projets ^0";
s[19]="Variables CSS^variables_css.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^tutorial Coller une variables CSS Variable calculée d'après une couleur Variable calculée d'après une mesure Le gestionnaire de variables css Utilisation d'une variables CSS Variable Css ^0";
s[20]="Nuage de tags^nuage_de_tags.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^nuage tutorial ^0";
s[21]="Création d'un blog^creation_d_un_blog.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^création d'un blog blog ^0";
s[22]="Aide multiformat^aide_multiformat.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^multiformat Aide multi formats ^0";
s[23]="Création d'un fil RSS^creation_d_un_fil_rss.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^objet associé RSS ^0";
s[24]="Formulaire de contact^formulaire_de_contact.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^ftp mail php contact formulaire ^0";
s[25]="Afficher un fil RSS^afficher_un_fil_rss.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^RSS PHP Afficher un fil RSS ^0";
s[26]="Fil d'ariane^fil_d_ariane.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^chemin de fer breadcrumb ariane ^0";
s[27]="Gérer l'impression des pages html^gerer_l_impression_des_pages_html.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^style print imprimer impression display css composant ^0";
s[28]="Gestion des tables des matières^gestion_des_tables_des_matieres.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^table composant sommaire matière liste liens ^0";
s[29]="Glossaire et Index^glossaire_et_index.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^Tutorial nuage composant Index Glossaire ^0";
s[30]="Créer des liens^creer_des_liens.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^^0";
s[31]="Mise en relation de rubriques^mise_en_relation_de_rubriques.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^^0";
s[32]="Notes de bas de page^notes_de_bas_de_page.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^notes note bas de page ^0";
s[33]="Créer un fichier d'aide CHM^creer_un_fichier_d_aide_chm.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^javascript htmlhelp flash chm aide ^0";
s[34]="Illustrations, légendes, les techniques pour votre documentation^illustrations__legendes__les_techniques_pour_votre_documentation.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^aide documentation image légende illustration ^0";
s[35]="Intégration CSS et HTML^integration_css_et_html.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^code fil d'ariane composant html css ^0";
s[36]="Intégration Jquery^integration_jquery.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^^0";
s[37]="Aides multiples avec un seul projet^aides_multiples_avec_un_seul_projet.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^^0";
s[38]="Contact^contact.htm^Dans l'idéal vous ne devez avoir aucun code javascript dans vos pages html, seulement une référence vers un fichier js, nous allons voir comment Help&Web vous facilite la tâche pour programmer proprement<div></br></div>^Contact ^0";
var results_location = "resultat.htm";
function search_form(tip_Form) {  
	if (tip_Form.elements['d'].value.length > 0) {
		document.cookie = '_hw_d_hw_=' + escape(tip_Form.elements['d'].value) + '; path=/';
		document.cookie = '_hw_n_hw_=0; path=/';
		
		window.location = results_location;
	}
}
var return_results = 10;
var include_num = 0;
var bold_query = 0;
var include_url = 0;
var cookie_data = '_hw_d_hw_=';
var cookie_ndata = '_hw_n_hw_=';
var cookies = document.cookie;
var p = cookies.indexOf(cookie_data);
var pn = cookies.indexOf(cookie_ndata);


if (p != -1) {
	var st = p + cookie_data.length;
	var en = cookies.indexOf(';', st);
	if (en == -1) {
		en = cookies.length;
	}
	var d = cookies.substring(st, en);
	d = unescape(d);
}
if (pn != -1) {
	var st = pn + cookie_ndata.length;
	var en = cookies.indexOf(';', st);
	if (en == -1) {
		en = cookies.length;
	}
	var n = cookies.substring(st, en);
}

if (d==null) {d=" ";}

var od = d;
var nr = return_results;
n = parseInt(n);
var nb = n + nr;
var nc = 0;
var nd = 0;
var r = new Array();
var co = 0;
var m = 0;

if (d.charAt(0) == '"' && d.charAt(d.length - 1) == '"') {
	m = 1;
}
var rn = d.search(/ or /i);
if (rn >= 0) {
	m = 2;
}

if (m == 0) {
	var woin = new Array();
	d = d.replace(/ and /gi, ' ');
	var w = d.split(' ');
	for (var a = 0; a < w.length; a++) {
		woin[a] = 0;
		if (w[a].charAt(0) == '-') {
			woin[a] = 1;
		}
	}
	for (var a = 0; a < w.length; a++) {
		w[a] = w[a].replace(/^\-|^\+/gi, '');
	}
	a = 0;
	for (var c = 0; c < s.length; c++) {
		var pa = 0;
		var nh = 0;
		for (var i = 0; i < woin.length; i++) {
			if (woin[i] == 0) {
				nh++;
				var pat = new RegExp(w[i], 'i');
				rn = s[c].search(pat);
				if (rn >= 0) {
					pa++;
				} else {
					pa = 0;
				}
			}
			if (woin[i] == 1) {
				var pat = new RegExp(w[i], 'i');
				var rn = s[c].search(pat);
				if (rn >= 0) {
					pa = 0;
				}
			}
		}
		if (pa == nh) {
			r[a] = s[c];
			a++;
		}
	}
	co = a;
}

if (m == 1) {
	d = d.replace(/"/gi, '');
	var a = 0;
	var pat = new RegExp(d, 'i');
	for (var c = 0; c < s.length; c++) {
		var rn = s[c].search(pat);
		if (rn >= 0) {
			r[a] = s[c];
			a++;
		}
	}
	co = a;
}

if (m == 2) {
	d = d.replace(/ or /gi, ' ');
	var w = d.split(' ');
	var a = 0;
	for (var i = 0; i < w.length; i++) {
		var pat = new RegExp(w[i], 'i');
		for (var c = 0; c < s.length; c++) {
		var rn = s[c].search(pat);
			if (rn >= 0) {
				var pa = 0;
				for (var e = 0; e < r.length; e++) {
					if (s[c] == r[e]) {
						pa = 1;
					}
				}
				if (pa == 0) {
					r[a] = s[c];
					a++;
					co++;
				}
			}
		}
	}
}

function write_cookie(nw) {
	document.cookie = '_hw_d_hw_=' + escape(od) + '; path=/';
	document.cookie = '_hw_n_hw_=' + nw + '; path=/';
}

var tip_Num = co;

function tip_query() {
	document.tip_Form.d.value = od;
}

function tip_num() {
	document.write(co);
}

function tip_out() {
	if (co == 0) {
		document.write('');
		return;
	}
	
	if (nr==0){n=0;nd=co;}
	else{
	     if (n + nr > co) {nd = co;} else {nd = n + nr;}
  }

	for (var a = n; a < nd; a++) {
		var os = r[a].split('^');
		if (bold_query == 1 && m == 0) {
			for (var i = 0; i < w.length; i++) {
				var lw = w[i].length;
				var tw = new RegExp(w[i], 'i');
				rn = os[2].search(tw);
				if (rn >= 0) {
					var o1 = os[2].slice(0, rn);
					var o2 = os[2].slice(rn, rn + lw);
					var o3 = os[2].slice(rn + lw);
					os[2] = o1 + '<b>' + o2 + '</b>' + o3; 
				}
			}
		}
		if (bold_query == 1 && m == 1) {
			var lw = d.length;
			var tw = new RegExp(d, 'i');
			rn = os[2].search(tw);
			if (rn >= 0) {
				var o1 = os[2].slice(0, rn);
				var o2 = os[2].slice(rn, rn + lw);
				var o3 = os[2].slice(rn + lw);
				os[2] = o1 + '<b>' + o2 + '</b>' + o3; 
			}
		}
		if (include_num == 1) {
			if (os[4] == '1') {
		
			document.write(a + 1, '. <a href="', os[1], '" target="_blank">', os[0], '</a>');
    
			} else {
			  document.write(a + 1, '. <a href="', os[1], '">', os[0], '</a>');
				
			}
				if (os[2].length > 1) {
			document.write('<br>', os[2]);
			}			
		} else {
			if (os[4] == '1') {
				if (a%2==0){
				document.write('<div ><a href="', os[1], '" target="_blank">', os[0], '</a></div>');
				} else {document.write('<div ><a href="', os[1], '" target="_blank">', os[0], '</a></div>');}
			} else {
				if (a%2==0){
				document.write('<div ><a href="', os[1], '">', os[0], '</a></div>');
				} else {document.write('<div ><a href="', os[1], '">', os[0], '</a></div>');}
			}
		}
		}
	if (co > nr) {

		nc = co - nb;
		if (nc > nr) {
			nc = nr;
		}
		document.write('<p>');
	}
	if (n > 1) {
		document.write('<a href="', results_location, '" onclick="write_cookie(', n - nr, ')">Précédent ', nr, '</a> &nbsp;');
	}
	if (nc > 0) {
		document.write('<a href="', results_location, '" onclick="write_cookie(', n + nr, ')">Suivant ', nc, '</a>');
	}
	
}
var d_first = true;q=document.getElementById("d");if (q!=null) {q.value = "Chercher"};/* niftycube.js */
/* Nifty Corners Cube - rounded corners with CSS and Javascript
Copyright 2006 Alessandro Fulciniti (a.fulciniti@html.it) */

var niftyOk=(document.getElementById && document.createElement && Array.prototype.push);
var niftyCss=false;

String.prototype.find=function(what){
return(this.indexOf(what)>=0 ? true : false);
}

var oldonload=window.onload;
if(typeof(NiftyLoad)!='function') NiftyLoad=function(){};
if(typeof(oldonload)=='function')
    window.onload=function(){oldonload();AddCss();NiftyLoad()};
else window.onload=function(){AddCss();NiftyLoad()};

function AddCss(){
niftyCss=true;
var l=CreateEl("link");
l.setAttribute("type","text/css");
l.setAttribute("rel","stylesheet");
l.setAttribute("href","niftyCube.css");
l.setAttribute("media","screen");
document.getElementsByTagName("head")[0].appendChild(l);
}

function Nifty(selector,options){
if(niftyOk==false) return;
if(niftyCss==false) AddCss();
var i,v=selector.split(","),h=0;
if(options==null) options="";
if(options.find("fixed-height"))
    h=getElementsBySelector(v[0])[0].offsetHeight;
for(i=0;i<v.length;i++)
    Rounded(v[i],options);
if(options.find("height")) SameHeight(selector,h);
}

function Rounded(selector,options){
var i,top="",bottom="",v=new Array();
if(options!=""){
    options=options.replace("left","tl bl");
    options=options.replace("right","tr br");
    options=options.replace("top","tr tl");
    options=options.replace("bottom","br bl");
    options=options.replace("transparent","alias");
    if(options.find("tl")){
        top="both";
        if(!options.find("tr")) top="left";
        }
    else if(options.find("tr")) top="right";
    if(options.find("bl")){
        bottom="both";
        if(!options.find("br")) bottom="left";
        }
    else if(options.find("br")) bottom="right";
    }
if(top=="" && bottom=="" && !options.find("none")){top="both";bottom="both";}
v=getElementsBySelector(selector);
for(i=0;i<v.length;i++){
    FixIE(v[i]);
    if(top!="") AddTop(v[i],top,options);
    if(bottom!="") AddBottom(v[i],bottom,options);
    }
}

function AddTop(el,side,options){
var d=CreateEl("b"),lim=4,border="",p,i,btype="r",bk,color;
d.style.marginLeft="-"+getPadding(el,"Left")+"px";
d.style.marginRight="-"+getPadding(el,"Right")+"px";
if(options.find("alias") || (color=getBk(el))=="transparent"){
    color="transparent";bk="transparent"; border=getParentBk(el);btype="t";
    }
else{
    bk=getParentBk(el); border=Mix(color,bk);
    }
d.style.background=bk;
d.className="niftycorners";
p=getPadding(el,"Top");
if(options.find("small")){
    d.style.marginBottom=(p-2)+"px";
    btype+="s"; lim=2;
    }
else if(options.find("big")){
    d.style.marginBottom=(p-10)+"px";
    btype+="b"; lim=8;
    }
else d.style.marginBottom=(p-5)+"px";
for(i=1;i<=lim;i++)
    d.appendChild(CreateStrip(i,side,color,border,btype));
el.style.paddingTop="0";
el.insertBefore(d,el.firstChild);
}

function AddBottom(el,side,options){
var d=CreateEl("b"),lim=4,border="",p,i,btype="r",bk,color;
d.style.marginLeft="-"+getPadding(el,"Left")+"px";
d.style.marginRight="-"+getPadding(el,"Right")+"px";
if(options.find("alias") || (color=getBk(el))=="transparent"){
    color="transparent";bk="transparent"; border=getParentBk(el);btype="t";
    }
else{
    bk=getParentBk(el); border=Mix(color,bk);
    }
d.style.background=bk;
d.className="niftycorners";
p=getPadding(el,"Bottom");
if(options.find("small")){
    d.style.marginTop=(p-2)+"px";
    btype+="s"; lim=2;
    }
else if(options.find("big")){
    d.style.marginTop=(p-10)+"px";
    btype+="b"; lim=8;
    }
else d.style.marginTop=(p-5)+"px";
for(i=lim;i>0;i--)
    d.appendChild(CreateStrip(i,side,color,border,btype));
el.style.paddingBottom=0;
el.appendChild(d);
}

function CreateStrip(index,side,color,border,btype){
var x=CreateEl("b");
x.className=btype+index;
x.style.backgroundColor=color;
x.style.borderColor=border;
if(side=="left"){
    x.style.borderRightWidth="0";
    x.style.marginRight="0";
    }
else if(side=="right"){
    x.style.borderLeftWidth="0";
    x.style.marginLeft="0";
    }
return(x);
}

function CreateEl(x){
return(document.createElement(x));
}

function FixIE(el){
if(el.currentStyle!=null && el.currentStyle.hasLayout!=null && el.currentStyle.hasLayout==false)
    el.style.display="inline-block";
}

function SameHeight(selector,maxh){
var i,v=selector.split(","),t,j,els=[],gap;
for(i=0;i<v.length;i++){
    t=getElementsBySelector(v[i]);
    els=els.concat(t);
    }
for(i=0;i<els.length;i++){
    if(els[i].offsetHeight>maxh) maxh=els[i].offsetHeight;
    els[i].style.height="auto";
    }
for(i=0;i<els.length;i++){
    gap=maxh-els[i].offsetHeight;
    if(gap>0){
        t=CreateEl("b");t.className="niftyfill";t.style.height=gap+"px";
        nc=els[i].lastChild;
        if(nc.className=="niftycorners")
            els[i].insertBefore(t,nc);
        else els[i].appendChild(t);
        }
    }
}

function getElementsBySelector(selector){
var i,j,selid="",selclass="",tag=selector,tag2="",v2,k,f,a,s=[],objlist=[],c;
if(selector.find("#")){ //id selector like "tag#id"
    if(selector.find(" ")){  //descendant selector like "tag#id tag"
        s=selector.split(" ");
        var fs=s[0].split("#");
        if(fs.length==1) return(objlist);
        f=document.getElementById(fs[1]);
        if(f){
            v=f.getElementsByTagName(s[1]);
            for(i=0;i<v.length;i++) objlist.push(v[i]);
            }
        return(objlist);
        }
    else{
        s=selector.split("#");
        tag=s[0];
        selid=s[1];
        if(selid!=""){
            f=document.getElementById(selid);
            if(f) objlist.push(f);
            return(objlist);
            }
        }
    }
if(selector.find(".")){      //class selector like "tag.class"
    s=selector.split(".");
    tag=s[0];
    selclass=s[1];
    if(selclass.find(" ")){   //descendant selector like tag1.classname tag2
        s=selclass.split(" ");
        selclass=s[0];
        tag2=s[1];
        }
    }
var v=document.getElementsByTagName(tag);  // tag selector like "tag"
if(selclass==""){
    for(i=0;i<v.length;i++) objlist.push(v[i]);
    return(objlist);
    }
for(i=0;i<v.length;i++){
    c=v[i].className.split(" ");
    for(j=0;j<c.length;j++){
        if(c[j]==selclass){
            if(tag2=="") objlist.push(v[i]);
            else{
                v2=v[i].getElementsByTagName(tag2);
                for(k=0;k<v2.length;k++) objlist.push(v2[k]);
                }
            }
        }
    }
return(objlist);
}

function getParentBk(x){
var el=x.parentNode,c;
while(el.tagName.toUpperCase()!="HTML" && (c=getBk(el))=="transparent")
    el=el.parentNode;
if(c=="transparent") c="#FFFFFF";
return(c);
}

function getBk(x){
var c=getStyleProp(x,"backgroundColor");
if(c==null || c=="transparent" || c.find("rgba(0, 0, 0, 0)"))
    return("transparent");
if(c.find("rgb")) c=rgb2hex(c);
return(c);
}

function getPadding(x,side){
var p=getStyleProp(x,"padding"+side);
if(p==null || !p.find("px")) return(0);
return(parseInt(p));
}

function getStyleProp(x,prop){
if(x.currentStyle)
    return(x.currentStyle[prop]);
if(document.defaultView.getComputedStyle)
    return(document.defaultView.getComputedStyle(x,'')[prop]);
return(null);
}

function rgb2hex(value){
var hex="",v,h,i;
var regexp=/([0-9]+)[, ]+([0-9]+)[, ]+([0-9]+)/;
var h=regexp.exec(value);
for(i=1;i<4;i++){
    v=parseInt(h[i]).toString(16);
    if(v.length==1) hex+="0"+v;
    else hex+=v;
    }
return("#"+hex);
}

function Mix(c1,c2){
var i,step1,step2,x,y,r=new Array(3);
if(c1.length==4)step1=1;
else step1=2;
if(c2.length==4) step2=1;
else step2=2;
for(i=0;i<3;i++){
    x=parseInt(c1.substr(1+step1*i,step1),16);
    if(step1==1) x=16*x+x;
    y=parseInt(c2.substr(1+step2*i,step2),16);
    if(step2==1) y=16*y+y;
    r[i]=Math.floor((x*50+y*50)/100);
    r[i]=r[i].toString(16);
    if(r[i].length==1) r[i]="0"+r[i];
    }
return("#"+r[0]+r[1]+r[2]);
}
/* domloadevent */
function addDOMLoadEvent(f){if(!window.__ADLE){var n=function(){if(arguments.callee.d)return;arguments.callee.d=true;if(window.__ADLET){clearInterval(window.__ADLET);window.__ADLET=null}for(var i=0;i<window.__ADLE.length;i++){window.__ADLE[i]()}window.__ADLE=null};if(document.addEventListener)document.addEventListener("DOMContentLoaded",n,false);/*@cc_on @*//*@if (@_win32)document.write("<scr"+"ipt id=__ie_onload defer src=//0><\/scr"+"ipt>");var s=document.getElementById("__ie_onload");s.onreadystatechange=function(){if(this.readyState=="complete")n()};/*@end @*/if(/WebKit/i.test(navigator.userAgent)){window.__ADLET=setInterval(function(){if(/loaded|complete/.test(document.readyState)){n()}},10)}window.onload=n;window.__ADLE=[]}window.__ADLE.push(f)}
/* XHRConnection.js */
// + --------------------------------------------------------------------------------------
// + XHRConnection
// + V1.3
// + Thanh Nguyen, http://www.sutekidane.net
// + 20.10.2005
// + http://creativecommons.org/licenses/by-nc-sa/2.0/fr/deed.fr
// + --------------------------------------------------------------------------------------
function XHRConnection() {
	
	// + ----------------------------------------------------------------------------------
	var conn = false;
	var debug = false;
	var datas = new String();
	var areaId = new String();
	// Objet XML
	var xmlObj;
	// Type de comportement au chargement du XML
	var xmlLoad;
	
	// + ----------------------------------------------------------------------------------
	try {
		conn = new XMLHttpRequest();		
	}
	catch (error) {
		if (debug) { alert('Erreur lors de la tentative de création de l\'objet \nnew XMLHttpRequest()\n\n' + error); }
		try {
			conn = new ActiveXObject("Microsoft.XMLHTTP");
		}
		catch (error) {
			if (debug) { alert('Erreur lors de la tentative de création de l\'objet \nnew ActiveXObject("Microsoft.XMLHTTP")\n\n' + error); }
			try {
				conn = new ActiveXObject("Msxml2.XMLHTTP");
			}
			catch (error) {
				if (debug) { alert('Erreur lors de la tentative de création de l\'objet \nnew ActiveXObject("Msxml2.XMLHTTP")\n\n' + error); }
				conn = false;
			}
		}
	}

	// + ----------------------------------------------------------------------------------
	// + setDebugOff
	// + Désactive l'affichage des exceptions
	// + ----------------------------------------------------------------------------------
	this.setDebugOff = function() {
		debug = false;
	};

	// + ----------------------------------------------------------------------------------
	// + setDebugOn
	// + Active l'affichage des exceptions
	// + ----------------------------------------------------------------------------------
	this.setDebugOn = function() {
		debug = true;
	};
	
	// + ----------------------------------------------------------------------------------
	// + resetData
	// + Permet de vider la pile des données
	// + ----------------------------------------------------------------------------------
	this.resetData = function() {
		datas = new String();
		datas = '';
	};
	
	// + ----------------------------------------------------------------------------------
	// + appendData
	// + Permet d'empiler des données afin de les envoyer
	// + ----------------------------------------------------------------------------------
	this.appendData = function(pfield, pvalue) {
		datas += (datas.length == 0) ? pfield+ "=" + escape(pvalue) : "&" + pfield + "=" + escape(pvalue);
	};
	
	// + ----------------------------------------------------------------------------------
	// + setRefreshArea
	// + Indique quel elment identifié par id est valoris lorsque l'objet XHR reoit une réponse
	// + ----------------------------------------------------------------------------------
	this.setRefreshArea = function(id) {
		areaId = id;
	};
	
	// + ----------------------------------------------------------------------------------
	// + createXMLObject
	// + Méthode permettant de créer un objet DOM, retourne la réfrence
	// + Inspiré de: http://www.quirksmode.org/dom/importxml.html
	// + ----------------------------------------------------------------------------------
	this.createXMLObject = function() {
		try {
			 	xmlDoc = document.implementation.createDocument("", "", null);
				xmlLoad = 'onload';
		}
		catch (error) {
			try {
				xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
				xmlLoad = 'onreadystatechange ';
			}
			catch (error) {
				if (debug) { alert('Erreur lors de la tentative de création de l\'objet XML\n\n'); }
				return false;
			}
		}
		return xmlDoc;
	}
	
	// + ----------------------------------------------------------------------------------
	// + Permet de définir l'objet XML qui doit être valorisé lorsque l'objet XHR reoit une réponse
	// + ----------------------------------------------------------------------------------
	this.setXMLObject = function(obj) {
		if (obj == undefined) {
				if (debug) { alert('Paramètre manquant lors de l\'appel de la méthode setXMLObject'); }
				return false;
		}
		try {
			//xmlObj = this.createXMLObject();
			xmlObj = obj;
		}
		catch (error) {
				if (debug) { alert('Erreur lors de l\'affectation de l\'objet XML dans la méthode setXMLObject'); }
		}
	}
	
	// + ----------------------------------------------------------------------------------
	// + loadXML
	// + Charge un fichier XML
	// + Entrées
	// + 	xml			String		Le fichier XML à charger
	// + ----------------------------------------------------------------------------------
	this.loadXML = function(xml, callBack) {
		if (!conn) return false;
		// Chargement pour alimenter un objet DOM
		if (xmlObj && xml) {
			if (typeof callBack == "function") {
				if (xmlLoad == 'onload') {
					xmlObj.onload = function() {
						callBack(xmlObj);
					}
				}
				else {
					xmlObj.onreadystatechange = function() {
						if (xmlObj.readyState == 4) callBack(xmlObj)
					}
				}
			}
			xmlObj.load(xml);
			return;
		}		
	}

	// + ----------------------------------------------------------------------------------
	// + sendAndLoad
	// + Connexion à la page désirée avec envoie des données, puis mise en attente de la réponse
	// + Entrées
	// + 	Url			String		L'url de la page à laquelle l'objet doit se connecter
	// + 	httpMode		String		La méthode de communication HTTP : GET, HEAD ou POST
	// + 	callBack		Objet		Le nom de la fonction de callback
	// + ----------------------------------------------------------------------------------
	this.sendAndLoad = function(Url, httpMode, callBack) {
		httpMode = httpMode.toUpperCase();
		conn.onreadystatechange = function() {
			if (conn.readyState == 4 && conn.status == 200) {
				// Si une fonction de callBack a été définie
				if (typeof callBack == "function") {
					callBack(conn);
					return;
				}
				// Si une zone destinée à récupérer le résultat a été définie
				else if (areaId.length > 0){
					try {
						document.getElementById(areaId).innerHTML = conn.responseText;
					}
					catch(error) {
						if (debug) { alert('Echec, ' + areaId + ' n\'est pas un objet valide'); }
					}
					return;
				}
			}
		};
		switch(httpMode) {
			case "GET":
				try {
					Url = (datas.length > 0) ? Url + "?" + datas : Url;
					conn.open("GET", Url);
					//conn.setRequestHeader("Content-Type",'text/html; charset="ISO-8859-15"');
          conn.send(null);
				}
				catch(error) {
					if (debug) { alert('Echec lors de la transaction avec ' + Url + ' via la méthode GET'); }
					return false;
				}
			break;
			case "POST":
				try {
					conn.open("POST", Url); 
					conn.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
					conn.send(datas);
				}
				catch(error) {
					if (debug) { alert('Echec lors de la transaction avec ' + Url + ' via la mthode POST'); }
					return false;
				}
			break;
			default :
				return false;
			break;
		}
		return true;
	};
	return this;
}

