// function aff_alerte()

// aff_alerte(txt, c_f , c_b , e_b , c_e , cl , logo , w_t , h_t , nb_bout , bout , titre , id , lang , idlang)
// txt = message d'alerte
// c_f = couleur de fond du tableau
// c_b = couleur de bordure du tableau
// e_b = epaisseur de la bordure de tableau
// c_e = couleur ecriture
// cl = class de l'ecriture
// logo = image du pop up
// w_t = largeur du pop up
// h_t = heuteur du pop up
// nb_bout = nombre de bouton ( 0 pour aucun bouton )
// bout = type du 1er bouton ( 0 = OK , 1 = ANNULER , 2 = OUI , 3 = NON , 4 correspond a un nouveau bouton , ... , vide = aucun bouton)
// titre = nom du popup
// id = identifiant du show ( pour les parties administrables
// lang = Nom de la langue ( ex : fr , uk , de , ... ) pour les parties administrables multi langues
// idlang = identifiant de la langue , pour les parties administrables multi langues.




// valeur par defaut modifiable lors de l'appel de la function

var graphs = "graphs\/"
var barre_popup = "barre_pop2.gif";


var bout0 = "OK|Ok|erreur.innerHTML=\'\';|100";
var bout1 = "ANNULER|Annuler|erreur.innerHTML=\'\';|100";
var bout2 = "OUI|Oui||100";
var bout3 = "NON|Non||100";
var bout4 = "FERMER|Fermer|erreur.innerHTML=\'\';|120";







function aff_alerte(txt,c_f,c_b,e_b,c_e,cl,logo,w_t,h_t,nb_bout,bout,titre,id,lang,idlang,id_erreur,id_affd) {

var id_aff = id_affd;

// Penser a modifier les valeurs par defaut pour que le pop up soit au même graphique que votre site

// methode qui va ranger les fenetres dans l'ordre de choix



//for (a=0;a<2;i++) {
//if (eval('i'+a)==0) { 
//eval('i'+a)=1; 
//break;
//}
//}
//alert(a);
//alert(eval('i'+a));




if ((typeof c_f == 'undefined') || (c_f=='')) { c_f = "#FFF0D1"; }
if ((typeof c_b == 'undefined') || (c_b=='')) { c_b = "#eca100"; }
if ((typeof e_b == 'undefined') || (e_b=='')) { e_b = "2"; }
if ((typeof c_e == 'undefined') || (c_e=='')) { c_e = "#000000"; }
if ((typeof cl  == 'undefined') || (cl==''))  { cl = "norm2"; }
if ((typeof logo == 'undefined') || (logo=='')) { logo = ""; }
if ((typeof w_t == 'undefined') || (w_t=='')) { w_t = "400"; }
if ((typeof h_t == 'undefined') || (h_t=='')) { h_t = "100"; }
var txt = txt;


var table;

table = "<table id=tableau"+id_erreur+" border=0 cellpadding=0 class="+cl+" cellspacing=0 width="+w_t+" height="+h_t+" bgcolor=\""+c_f+"\" style='border:"+e_b+"px solid "+c_b+";filter:progid:DXImageTransform.Microsoft.dropShadow(Color=#999999,offX=5,offY=5,positive=true);width:'>";
table = table +"<tr><td style='border-bottom:1px solid #eca100;' height=24  style='background:url("+graphs+barre_popup+");BACKGROUND-REPEAT:repeat-x;background-color:#FFF0D1;' >&nbsp;&nbsp;<b>"+titre+"</b></td></tr>";
table = table +"<tr><td colspan=2 ><table border=0 class="+cl+" cellspacing=0><tr><td>"
// bouton diminution
//table = table +"<div id=\"Layer6"+id_erreur+"\" style=\"position:absolute; left:"+parseInt((w_t)-34)+"px; top:6px; z-index:10\" align=right>"
//table = table +"<a href=\"#\" onclick=\"diminue('"+w_t+"','"+h_t+"','"+id_erreur+"','"+id_aff+"');\"><img src=\"graphs/diminue_pop.gif\" border=0></a></div>"
// bouton aggrandi
//table = table +"<div id=\"Layer7"+id_erreur+"\" style=\"position:absolute; left:"+parseInt((w_t)-16)+"px; top:6px; z-index:10\" align=right>"
//table = table +"<a href=\"#\" onclick=\"aggrandie('"+w_t+"','"+h_t+"','"+id_erreur+"','"+id_aff+"');\"><img src=\"graphs/aggrandi_pop.gif\" border=0></a></div>"
// bouton fermeture

table = table +"<div id=\"Layer5"+id_erreur+"\" style=\"position:absolute; left:"+parseInt((w_t))+"px; top:1px; z-index:10\" align=right>"
table = table +"<a href=\"#\" onclick=\"erreur"+id_erreur+".innerHTML='';\"><img src=\"graphs/croix_pop2.gif\" border=0></a></div><font color="+c_e+">"
table = table + txt
if (nb_bout == 1) {
	table = table + "</td></tr></table></td></tr><tr><td align=center valign=bottom><input type=button name=\""+eval('bout'+bout).split('|')[0]+"\" value=\""+eval('bout'+bout).split('|')[1]+"\"  class=bouton style='width:"+eval('bout'+bout).split('|')[3]+"px;' onclick=\""+eval('bout'+bout).split('|')[2]+"\">"
}

if (nb_bout == 2) {
	table = table + "</td></tr></table></td></tr><tr><td align=center valign=bottom>";
	table = table + "<input type=button name=\""+eval('bout'+bout.split('|')[0]).split('|')[0]+"\" value=\""+eval('bout'+bout.split('|')[0]).split('|')[1]+"\" class=bouton style='width:"+eval('bout'+bout.split('|')[0]).split('|')[3]+";' onclick=\""+eval('bout'+bout.split('|')[0]).split('|')[2]+"\">&nbsp;&nbsp;&nbsp;";
	table = table + "<input type=button name=\""+eval('bout'+bout.split('|')[1]).split('|')[0]+"\" value=\""+eval('bout'+bout.split('|')[1]).split('|')[1]+"\" class=bouton style='width:"+eval('bout'+bout.split('|')[1]).split('|')[3]+";' onclick=\""+eval('bout'+bout.split('|')[1]).split('|')[2]+"\">";
}

if (nb_bout == 3) {
	table = table + "</td></tr></table></td></tr><tr><td align=center valign=bottom>";
	table = table + "<input type=button name=\""+eval('bout'+bout.split('|')[0]).split('|')[0]+"\" value=\""+eval('bout'+bout.split('|')[0]).split('|')[1]+"\" class=bouton style='width:"+eval('bout'+bout.split('|')[0]).split('|')[3]+";' onclick=\""+eval('bout'+bout.split('|')[0]).split('|')[2]+"\">&nbsp;&nbsp;&nbsp;";
	table = table + "<input type=button name=\""+eval('bout'+bout.split('|')[1]).split('|')[0]+"\" value=\""+eval('bout'+bout.split('|')[1]).split('|')[1]+"\" class=bouton style='width:"+eval('bout'+bout.split('|')[1]).split('|')[3]+";' onclick=\""+eval('bout'+bout.split('|')[1]).split('|')[2]+"\">&nbsp;&nbsp;&nbsp;";
	table = table + "<input type=button name=\""+eval('bout'+bout.split('|')[2]).split('|')[0]+"\" value=\""+eval('bout'+bout.split('|')[2]).split('|')[1]+"\" class=bouton style='width:"+eval('bout'+bout.split('|')[2]).split('|')[3]+";' onclick=\""+eval('bout'+bout.split('|')[2]).split('|')[2]+"\">"
}
table = table + "</font></td></tr></table>";
eval('erreur'+id_erreur).innerHTML = table;

// partie pour les sites multilangue

if ((id!='') && (lang!='') && (idlang!=''))
{
	if (eval('di'+id).style.display=='none') {show(id);}
	selectLang(lang,id,idlang);
	return false;
}

// pour les sites monolangue

if ((id!='') && (lang=='') && (idlang==''))
	{
	if (eval('di'+id).style.display=='none') {show(id);}
	return false;
	}


}



if (clic==1) {

<!--

// Script trouvé sur Le Webmestre www.le-webmestre.net info@le-webmestre.net
// Retrouvez des centaines de scripts et bien plus...

/*
Drag and Drop Script- 
© Dynamic Drive (www.dynamicdrive.com)
For full source code, installation instructions,
100's more DHTML scripts, and Terms Of
Use, visit dynamicdrive.com
*/

var dragapproved=false
var z,x,y
function move(){
if (event.button==1&&dragapproved){
z.style.pixelLeft=temp1+event.clientX-x
z.style.pixelTop=temp2+event.clientY-y
return false
}
}
function drags(){
if (!document.all)
return
if (event.srcElement.className=="drag"){
dragapproved=true
z=event.srcElement
temp1=z.style.pixelLeft
temp2=z.style.pixelTop
x=event.clientX
y=event.clientY
document.onmousemove=move
}
}
document.onmousedown=drags
document.onmouseup=new Function("dragapproved=false")
//-->



// VARIABLE À UTILISER POUR AJOUTER UN ÉLÉMENT
var dragDrop = new DragDrop();

// CLASSE PERMETTANT DE GÉRER LE DRAG & DROP
function DragDrop()
{
	// Tableau contenant les id des éléments
	this.elements = new Array;

	// Variable contenant l'instance sur l'élément étant en train d'être déplacé
	this.elementActif = null;

	// Empèche les selections sur la page
	document.onselectstart = NoSelect;
	document.ondragstart = NoSelect;

	// Méthode de la classe
	this.Add = DragDrop_Add;
}

// MÉTHODE PERMETTANT D'AJOUTER UN ÉLÉMENT DEVANT ÊTRE DÉPLACABLE
function DragDrop_Add( idElement )
{
	// Recherche le prochain emplacement libre
	var indice = 0;
	while( this.elements[ indice ] != null )
		indice ++;

	// Ajoute l'élément
	this.elements[ indice ] = idElement;

	// Modifie le style de positionnement de l'élément
	GetElement( idElement ).style.position = "absolute";

	// Modifie les fonctions à appeler lors d'un évènement sur l'élément
	GetElement( idElement ).onmousedown = DragDrop_Start;
	GetElement( idElement ).onmouseup = DragDrop_Stop;
}

// FONCTION PERMETTANT DE COMMENCER LE DÉPLACEMENT
function DragDrop_Start()
{
	if( dragDrop.elementActif == null )
	{
		// Parcourt les éléments et les enlèves du premier plan
		var indice = 0;
		while( dragDrop.elements[ indice ] != null )
		{
			if( GetElement( dragDrop.elements[ indice ] ).style.zIndex > 1 )
				GetElement( dragDrop.elements[ indice ] ).style.zIndex = GetElement( dragDrop.elements[ indice ] ).style.zIndex - 1;

			indice ++;
		}

		// Met l'élément au premier plan
		this.style.zIndex = 5000;

		// Met l'élément actif à jour
		dragDrop.elementActif = this;

		// Modifie la fonction appelée lorsque le curseur bouge au-dessus de la fenêtre
		document.onmousemove = DragDrop_Move;
	}
}

// FONCTION PERMETTANT D'ARRETER LE DÉPLACEMENT
function DragDrop_Stop()
{
	if( dragDrop.elementActif != null )
	{
		// Met l'élément actif à jour
		dragDrop.elementActif = null;


		// Modifie la fonction appelée lorsque le curseur bouge au-dessus de la fenêtre
		document.onmousemove = null;
	}
}

// FONCTION PERMETTANT DE DÉPLACER L'ÉLÉMENT ACTIF
function DragDrop_Move( evenementSouris )
{
	// Récupère les coordonnées de la souris d'après le navigateur
	var souris;
	if( document.all )
		souris = event;
	else
		souris = evenementSouris;

	// Positionne l'élément de manière à ce qu'il soit centré par rapport au curseur
	dragDrop.elementActif.style.left = souris.clientX + document.body.scrollLeft - dragDrop.elementActif.offsetWidth / 2;
	dragDrop.elementActif.style.top = souris.clientY + document.body.scrollTop - dragDrop.elementActif.offsetHeight / 2;
}

// FONCTION PERMETTANT D'ARRÊTER UNE SELECTION DANS LA PAGE
function NoSelect()
{
	return false;
}

// FONCTION PERMETTANT DE RÉCUPÉRER L'INSTANCE D'UN DES ÉLÉMENTS DE LA PAGE
function GetElement( idElement )
{
	if( document.all )
		return document.all( idElement );

	return document.getElementById( idElement );
}
dragDrop.Add( "Layer4" );
}


function diminue(w_t,h_t,nb,id_i) {

if (document.getElementById('frameadr'+nb)) {
document.getElementById('frameadr'+nb).style.display='none';
var zone = parseInt(id_i);
document.getElementById('Layer'+nb+'4').style.top=''+(1+(parseInt(zone)*25))+'px';
document.getElementById('Layer'+nb+'4').style.left='670px';
document.getElementById('tableau'+nb).style.height='10px';
document.getElementById('tableau'+nb).style.width='300px';
document.getElementById('Layer6'+nb).style.left =''+(parseInt(275)-34)+'px';
document.getElementById('Layer7'+nb).style.left =''+(parseInt(275)-16)+'px';
document.getElementById('Layer5'+nb).style.left =''+(parseInt(275))+'px';
calshowHideSelect(1);
old_zone="";
old_nb="";
}
}

function aggrandie(w_t,h_t,nb,id_i) {

if (nb==98){
nb_top = 100;
nb_left = 100;
}

document.getElementById('frameadr'+nb).style.display='block';
document.getElementById('Layer'+nb+'4').style.top=''+(parseInt(nb_top))+'px';
document.getElementById('Layer'+nb+'4').style.left=''+(parseInt(nb_left))+'px';
document.getElementById('tableau'+nb).style.height=''+(parseInt(h_t))+'px';
document.getElementById('tableau'+nb).style.width=''+(parseInt(w_t))+'px';
document.getElementById('Layer6'+nb).style.left =''+(parseInt(w_t)-34)+'px';
document.getElementById('Layer7'+nb).style.left =''+(parseInt(w_t)-16)+'px';
document.getElementById('Layer5'+nb).style.left =''+(parseInt(w_t))+'px';

if (((old_nb!="") && (old_nb!=nb)) && ((old_zone!="") || (old_zone!=zone) ||(old_zone!=id_i)) )
	{
	diminue(w_t,h_t,old_nb,old_zone);
	calshowHideSelect(0);

	}
	
if ((old_nb=="") && (old_zone=="")){
	old_zone = id_i;
}else{
	old_zone = zone;
}
old_nb = nb;
calshowHideSelect(0);
}
