//Permettre animation de références
<script language="javascript">AC_FL_RunContent = 0;</script>
<script src="AC_RunActiveContent.js" language="javascript"></script>
//
//*-------------------------------------------------------------------------------*
//*-- Fonctions permettant d'afficher / cacher le formulaire MoreInfo			--*
//*-------------------------------------------------------------------------------*
//
/*Les 2 valeurs suivantes sont à adapter en fonction de vos besoins.*/
//	Vitesse d'aggrandissement de la div (en millisecondes)
var VitesseOuverture = 20;
//	Augmentation de la taille de la div en pixels.
var Incrementation = 30;
/* Script par SirJojO */
/* Forums http://www.editeurjavascript.com/ */
//	Identifiant du lien
var leLien = 'MoreInfo';
//	Identifiant de la div
var NomDiv = 'DivCachee';
//	Largeur et Hauteur de la div (en pixels)
//	A adapter en fonction du contenu du formulaire.
var PropRight = 714;
var PropBottom = 500;

var ouverture;
function Enregistre() { window.document.getElementById(leLien).onclick=ouvrir; }
function ouvrir() { window.document.getElementById(leLien).onclick=''; window.document.getElementById(NomDiv).style.clip="rect(auto, 0px, 0px, auto)"; window.document.getElementById(NomDiv).style.display='block'; ouverture = window.setInterval("aggrandissement()",VitesseOuverture);}
function aggrandissement() { clipProp = (window.document.getElementById(NomDiv).style.clip).split(" "); pixel = "px"; if(!document.all)	pixel+=","; theRight = new Number(clipProp[1].replace(new RegExp(pixel), '')); theBottom = new Number(clipProp[2].replace(new RegExp(pixel), '')); if(theBottom<PropBottom) /* Script par SirJojO */ theBottom = theBottom+Incrementation; if(theRight<PropRight) /* Forums http://www.editeurjavascript.com/ */ theRight = theRight+Incrementation; else {	window.clearInterval(ouverture); window.document.getElementById(leLien).onclick=cacheBloc;} window.document.getElementById(NomDiv).style.clip="rect(auto, "+theRight+"px, "+theBottom+"px, auto)";}
function cacheBloc() { window.document.getElementById(NomDiv).style.display='none'; window.document.getElementById(leLien).onclick=ouvrir;}
window.onload=Enregistre;
//
//*------------------------------------------------------------------------------*
//
function Show_Stuff(elementid,action){
      element = document.getElementById(elementid);
      if (action == "show"){
        element.style.display = "block";
      }
      if (action == "hide"){
        element.style.display = "none";
      }
    }
function DisplayWindowStatus(texte)
{
	window.status=texte;
}
function DisplayWindowStatusDefault()
{
	window.status="Transatel solution";
}
//
//*-------------------------------------------------------------------------------*
//*-- Fonctions permettant d'afficher / cacher une InfoBulle (DemoUms.inc)		--*
//*-------------------------------------------------------------------------------*
//
IE4 = (document.all) ? 1 : 0;
NS4 = (document.layers) ? 1 : 0;
FX4 = (document.getElementById) ? 1 : 0;
VERSION4 = (IE4 | NS4 | FX4) ? 1 : 0;
if (!VERSION4) event = null;
function helpGetOffset(obj, coord)
{
	var val = obj["offset"+coord] ;
	if (coord == "Top") val += obj.offsetHeight;
	while ((obj = obj.offsetParent )!=null)
	{
		val += obj["offset"+coord];
		if (obj.border && obj.border != 0) val++;
	}
	return val;
}
function helpDown()
{
	if(IE4)
	{
		document.all.helpBox.style.visibility = "hidden";
	}
	else if(NS4)
	{
	document.helpBox.visibility = "hidden";
	}
	if(FX4)
	{
		document.getElementById('helpBox').style.visibility = "hidden";
	}
}
function helpOver(event,texte)
{
	if (!VERSION4) return;
	var ptrObj, ptrLayer;
	if(IE4)
	{
		ptrObj = event.srcElement;
		ptrLayer = document.all.helpBox;
	}
	else if(NS4)
	{
		ptrObj = event.target;
		ptrLayer = document.helpBox;
	}
	else if(FX4)
	{
		ptrObj = event.target;
		ptrLayer = document.getElementById('helpBox');
	}
	if (!ptrObj.onmouseout)
	{
		ptrObj.onmouseout = helpDown;
	}
	var str = '<DIV CLASS="helpBoxDIV">'+texte+'</DIV>';
	if(IE4)
	{
		ptrLayer.innerHTML = str;
		ptrLayer.style.top  = helpGetOffset (ptrObj,"Top") + 2;
		ptrLayer.style.left = helpGetOffset (ptrObj,"Left") + 30;
		ptrLayer.style.visibility = "visible";
	}
	else if(NS4)
	{
		ptrLayer.document.write (str);
		ptrLayer.document.close ();
		ptrLayer.document.bgColor = "yellow";
		ptrLayer.top  = ptrObj.y + 20;
		ptrLayer.left = ptrObj.x;
		ptrLayer.visibility = "show";
	}
	else if(FX4)
	{
		ptrLayer.innerHTML = str;
		ptrLayer.style.top  = helpGetOffset (ptrObj,"Top") + 2;
		ptrLayer.style.left = helpGetOffset (ptrObj,"Left") + 30;
		ptrLayer.style.visibility = "visible";
	}
}
//
//*-------------------------------------------------------------------------------*
//*-- Fonctions permettant d'afficher / cacher un message dans une balise div	--*
//*-------------------------------------------------------------------------------*
//
function on(texte)
{
   	eval(texte).style.visibility = "visible";
	//texte.visibility=visible;
}
function off(texte)
{
   	eval(texte).style.visibility = "hidden";
	//texte.visibility=hidden;
}
//
//*-------------------------------------------------------------------*
//*-- Fonction permettant d'afficher un message dans une balise div	--*
//*-------------------------------------------------------------------*
//
//
function ChangeMessage(champ, message)
{
	if(document.getElementById)
	document.getElementById(champ).innerHTML = message;
}
//
//*---------------------------------------------------------------------------*
//*-- Fonctions permettant de gérer le changement de taille de la fenêtre	--*
//*-- en vue de repositionner le Logo										--*
//*---------------------------------------------------------------------------*
//
function largeur_fenetre()
{
	if (window.innerWidth) return window.innerWidth;
	else if (document.body && document.body.offsetWidth) return document.body.offsetWidth;
	else return 0;
}

function hauteur_fenetre()
{
	if (window.innerHeight) return window.innerWidth;
	else if (document.body && document.body.offsetHeight) return document.body.offsetHeight;
	else return 0;
}
function xpos_logo()
{
	if (window.innerWidth)
	{
		xpos= ((window.innerWidth - 720)/2);
		document.getElementById("LogoSpan").style.left = xpos;
		return xpos;
	}
	else if (document.body && document.body.offsetWidth)
	{
		 xpos= ((document.body.offsetWidth - 720)/2);
		 LogoSpan.style.left = xpos;
		 return xpos;
	}
	else return 0;
}
function reconstruction()
{
	if (largeur != largeur_fenetre() || hauteur != hauteur_fenetre())
	window.history.go(0);
}
//
//*-----------------------------------------------------------------------------------------------------------*
//*-- Fonction d'affichage/Cache de tout Texte d'un Objet passé en paramêtre (Ex: Pays sur Page Accueil)	--*
//*-----------------------------------------------------------------------------------------------------------*
//
function Affiche_Cache(nObjet,Txt)
{
	var ns4=document.layers;
	var ie4=document.all;
	var ns6=document.getElementById&&!document.all;
	//
	if(ie4)
	{ // Internet explorer
   		eval(nObjet).innerHTML = Txt;
   		eval(nObjet).style.visibility = (eval(nObjet).style.visibility=='visible'?'hidden':'visible');
 	}
	else if(ns4)
	{ // Netscape 4.x
		document.eval(nObjet).visibility = (document.eval(nObjet).visibility=='show'?'hidden':'show');
		document.eval(nObjet).innerHTML = Txt;
	}
	else if(ns6)
	{ // Netscape 6 (mozilla)
		var divns6 = document.getElementsByTagName("div");
		divns6[nObjet].style.visibility = (divns6[nObjet].style.visibility=='visible'?'hidden':'visible');
		divns6[nObjet].innerHTML = Txt;
 	}
}
//
//*---------------------------------------------------------------------------------------*
//*-- Fonction permettant d'ouvrir une popup avec une image								--*
//*---------------------------------------------------------------------------------------*
//
function open_popup(chemin)
{
	i1 = new Image;
	i1.src = chemin;
	html = '<HTML><HEAD><TITLE>Image</TITLE><link rel="stylesheet" href="/common/inc/common_stylesheet.css"></HEAD><BODY LEFTMARGIN=0 MARGINWIDTH=0 TOPMARGIN=0 MARGINHEIGHT=0 bgcolor=white><table><tr><td><CENTER><a class=link6 href="javascript:window.close()"><IMG SRC="'+chemin+'" BORDER=0 NAME=imageTest onLoad="window.resizeTo(document.imageTest.width+14,document.imageTest.height+80)"></a></CENTER></td></tr><tr><td align=center><!--<a class=link6 href="javascript:window.close()">Close</a>--><p></td></tr></table></BODY></HTML>';
	popupImage = window.open('','_blank','screenX=0,left=0, screenY=0, top=0, toolbar=0,location=0,directories=0,menuBar=0,scrollbars=1,resizable=1');
	popupImage.document.open();
	popupImage.document.write(html);
	popupImage.document.close()
};
function open_popup1(chemin)
{
	i1 = new Image;
	i1.src = chemin;
	html = '<HTML><HEAD><TITLE>Image</TITLE><link rel="stylesheet" href="/common/inc/common_stylesheet.css"></HEAD><BODY LEFTMARGIN=0 MARGINWIDTH=0 TOPMARGIN=0 MARGINHEIGHT=0 bgcolor=white><table><tr><td><CENTER><IMG SRC="'+chemin+'" BORDER=0 NAME=imageTest onLoad="window.resizeTo(document.imageTest.width+14,document.imageTest.height+80)"></CENTER></td></tr><tr><td align=center><a class=link6 href="javascript:window.close()">Close</a><p></td></tr></table></BODY></HTML>';
	popupImage = window.open('','_blank','screenX=0,left=0, screenY=0, top=0, toolbar=0,location=0,directories=0,menuBar=0,scrollbars=0,resizable=1');
	popupImage.document.open();
	popupImage.document.write(html);
	popupImage.document.close()
};
function open_popup2(chemin)
{
	i1 = new Image;
	i1.src = chemin;
	html = '<HTML><HEAD><TITLE>Image</TITLE><link rel="stylesheet" href="/common/inc/common_stylesheet.css"></HEAD><BODY LEFTMARGIN=0 MARGINWIDTH=0 TOPMARGIN=0 MARGINHEIGHT=0 bgcolor=white><table><tr><td><CENTER><IMG SRC="'+chemin+'" BORDER=0 NAME=imageTest onLoad="window.resizeTo(document.imageTest.width+14,document.imageTest.height+80)"></CENTER></td></tr><tr><td align=center><a class=link6 href="javascript:window.close()">Close</a><p></td></tr></table></BODY></HTML>';
	popupImage = window.open('','_blank','screenX=0,left=0, screenY=0, top=0, toolbar=0,location=0,directories=0,menuBar=0,scrollbars=1,resizable=1');
	popupImage.document.open();
	popupImage.document.write(html);
	popupImage.document.close()
};
//
function afficheMaxi(chemin,fileLabel)
{
	//*-- Objet Image	--*
	var i1 = new Image;
	i1.src = chemin;
	//*-- Taille Image	--*
 	var h = i1.height;
  	var w = i1.width;
	html = '<HTML><HEAD><TITLE>'+fileLabel+'</TITLE></HEAD><BODY LEFTMARGIN=0 MARGINWIDTH=0 TOPMARGIN=0 MARGINHEIGHT=0 bgcolor=black><table border=0 cellspacing=0 cellpadding=0><tr><td align=center valign=middle><a class=link6 href="javascript:window.close()"><IMG SRC="'+chemin+'" BORDER=0 NAME=imageTest alt="'+fileLabel+'" onLoad="window.resizeTo(document.imageTest.width+14,document.imageTest.height+40)"></a></td></tr></table></BODY></HTML>';
	popupImage = window.open('','_blank','screenX=0,left=0, screenY=0, top=0, toolbar=0,location=0,directories=0,menuBar=0,scrollbars=0,resizable=1');
	popupImage.document.open();
	popupImage.document.write(html);
	popupImage.document.close()
}
//
//*---------------------------------------------------------------------------------------*
//*-- Fonction permettant d'ouvrir une popup centrée en fontion de la taille donnée	--*
//*---------------------------------------------------------------------------------------*
//
function popup_new(page,largeur,hauteur,options)
{
	var top=(screen.height-hauteur)/2;
	var left=(screen.width-largeur)/2;
	fen = window.open(page,"_blank","top="+top+",left="+left+",width="+largeur+",height="+hauteur+","+options);
}
function submit_formulaire()
{
	setTimeout('document.formulaire.submit()',1000);
}
function OpenPopup(formulaire)
{
	if (formulaire.ListeUrl.selectedIndex != 0)
		{
		window.open(formulaire.ListeUrl.options[formulaire.ListeUrl.selectedIndex].value,'fenetre','top=0,left=0');
	 	}
}
//
//*-----------------------------------------------------------------------------------------------*
//*-- fonction d'impression d'une partie de page						--*
//*-- Il faut encadrer la zone à imprimer par un tag						--*
//*-- <div id="contenu"> < !-- #BeginEditable "texte" -- > ... < !-- #EndEditable -- ></div> 	--*
//*-----------------------------------------------------------------------------------------------*
//
function ImprimerPage()
{
	printIt();
}
function printIt()
{
	if (document.all)
	{
		printText = contenu.innerHTML;
		popup_resultat = window.open('','_print','width=800,height=400, scrollbars=yes, resizable=yes');
		popup_resultat.document.open();
		popup_resultat.document.writeln('<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1"><link rel="stylesheet" href="/common/inc/common_stylesheet.css"></HEAD><BODY BGCOLOR=#FFFFFF>');
		popup_resultat.document.writeln(printText);
		popup_resultat.document.writeln('</body></html>');
		popup_resultat.document.close();
		popup_resultat.print();
	}
	if (document.layers)
	{
		if (document.URL.indexOf("/html/") == -1 )
		{
			window.print();
		}
		else
		{
			// popup_resultat = window.open('/asp/imprimer/imprimer_page.asp','_print','scrollbars=yes, resizable=yes,width=700,height=500');
			// popup_resultat.print();
			window.print();
		}
	}
}
//
//*-----------------------------------------------*
//*-- fonction de soumission d'un formulaire 	--*
//*-----------------------------------------------*
//
function subform(form)
{
	form.submit();
	setTimeout('',5000);
}
//
//*-------------------------------------------------------*
//*-- Controle du formulaire de login transatel 	--*
//*-------------------------------------------------------*
//
function verif_form_mytransatel_log(f)
{
	//login test
	testm = false;
	//if (f.elements[0].value=='')
	//{
		alert('Your login is incorrect.');
		return testm ;
	//}
	//password test
	testm = false;
	//if (f.elements[1].value=='')
	//{
		alert('Your password is incorrect.');
		return testm ;
	//}
}
function load()
{
	if (document.images)
	{
		this.length=preload.arguments.length;
		for (var i=0;i<this.length;i++)
		{
			this[i+1]=new Image();
			this[i+1].src=preload.arguments[i];
		}
	}
}
//
//*---------------------------------------------------------------------------------------*
//*-- Cette fonction charge dans le cache toutes les images passées en paramètre	--*
//*---------------------------------------------------------------------------------------*
//
function preload()
{
	var temp=new load("/img/bt_fu_off.gif","/img/bt_fu_on.gif",
			  "/img/bt_ft_off.gif","/img/bt_ft_on.gif",
			  "/img/bt_eb_off.gif","/img/bt_eb_on.gif",
			  "/img/bt_mo_off.gif","/img/bt_mo_on.gif",
			  "/img/accueil_ft_out.gif","/img/accueil_ft_over.gif",
			  "/img/accueil_tms_out.gif","/img/accueil_tms_over.gif",
			  "/img/accueil_ci_out.gif","/img/accueil_ci_over.gif",
			  "/img/accueil_ci_bullet_out.gif"
			  );
}
function MM_swapImgRestore()
{
	var i,x,a=document.MM_sr;
	for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++)
		x.src=x.oSrc;
}
function MM_findObj(n, d)
{
	var p,i,x;
	if(!d) d=document;
	if((p=n.indexOf("?"))>0&&parent.frames.length)
	{
    		d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);
    	}
  	if(!(x=d[n])&&d.all) x=d.all[n];
  		for (i=0;!x&&i<d.forms.length;i++)
  			x=d.forms[i][n];
  	for(i=0;!x&&d.layers&&i<d.layers.length;i++)
  		x=MM_findObj(n,d.layers[i].document);
  	return x;
}
function MM_swapImage()
{
	var i,j=0,x,a=MM_swapImage.arguments;
	document.MM_sr=new Array;
	for(i=0;i<(a.length-2);i+=3)
   		if ((x=MM_findObj(a[i]))!=null)
   		{
   			document.MM_sr[j++]=x;
   			if(!x.oSrc)
   				x.oSrc=x.src;
   			x.src=a[i+2];
   		}
}
function MM_findObj(n, d)
{
	var p,i,x;
	if(!d)
		d=document;
	if((p=n.indexOf("?"))>0&&parent.frames.length)
	{
    		d=parent.frames[n.substring(p+1)].document;
    		n=n.substring(0,p);
    	}
  	if(!(x=d[n])&&d.all)
  		x=d.all[n];
  	for (i=0;!x&&i<d.forms.length;i++)
  		x=d.forms[i][n];
  	for(i=0;!x&&d.layers&&i<d.layers.length;i++)
  		x=MM_findObj(n,d.layers[i].document);
  	return x;
}
function MM_showHideLayers()
{
	var i,p,v,obj,args=MM_showHideLayers.arguments;
  	for (i=0; i<(args.length-2); i+=3)
  	if ((obj=MM_findObj(args[i]))!=null)
  	{
  		v=args[i+2];
    		if (obj.style)
    		{
    			obj=obj.style;
    			v=(v=='show')?'visible':(v='hide')?'hidden':v;
    		}
    		obj.visibility=v;
    	}
}
//
//*-------------------------------------------------------------------------------------------------------*
//*-- creation d'une pop-up sans barre de defilt + lien ouvrant un document sur la fenetre d'origine 	--*
//*-------------------------------------------------------------------------------------------------------*
//
function popup(nom_popup,x,y)
{
	fen = window.open(nom_popup,'poppage','toolbars=no,scrollbars=no,location=no,statusbar=no,menubars=no,directories=no,resizable=no,width=400,height=450,screenX=200, screenY=100, left=200,top=100');
}
//
//*-----------------------------------------------------------------------*
//*-- creation d'une pop-up de saisie de passwordsans barre de defilt	--*
//*-- + lien ouvrant un document sur la fenetre d'origine 		--*
//*-----------------------------------------------------------------------*
//
function popup_passwd(nom_popup,x,y)
{
	fen = window.open(nom_popup,'poppage','toolbars=no,scrollbars=no,location=no,statusbar=no,menubars=no,directories=no,resizable=no,width=250,height=200,screenX=300, screenY=200, left=300,top=200');
}
function open_window(votre_page)
{
	var hauteur_popup=500;
	var H = (screen.height - hauteur_popup) / 2;
	var largeur_popup=450;
	var L = (screen.width - largeur_popup) / 2;
	pop_up = window.open(votre_page,"Popup_pub","status=no,scrollbars=no,resizable=no,location=no,directories=no,height="+hauteur_popup+",width="+largeur_popup+",top="+H+",left="+L);
}
function VersionNavigateur(Netscape, Explorer)
{
	if ((navigator.appVersion.substring(0,3) >= Netscape && navigator.appName == 'Netscape') ||
	(navigator.appVersion.substring(0,3) >= Explorer && navigator.appName.substring(0,9) == 'Microsoft'))
		return true;
	else
		return false;
}
var isIE4 = false;
function CheckBrowser()
{
	if (navigator.appName == "Microsoft Internet Explorer" && navigator.appVersion.charAt(0) >= 4)
	{
		isIE4 = true;
	}
}
function mOvr(src,clrOver)
{
	if (!src.contains(event.fromElement))
	{
		src.style.cursor = 'hand';
		src.bgColor = clrOver;
	}
}
function mOut(src,clrIn)
{
	if (!src.contains(event.toElement))
	{
		src.style.cursor = 'default';
		src.bgColor = clrIn;
	}
}
function mClk(src,clrClk,urlClk)
{

	src.bgColor = clrClk;
	document.location = urlClk
}
function mOvrTop(src,clrOver)
{
	if (!src.contains(event.fromElement))
	{
		src.style.cursor = 'hand';
		src.bgColor = clrOver;
	}
}
function mOutTop(src,clrIn)
{
	if (!src.contains(event.toElement))
	{
	 	src.style.cursor = 'default';
	 	src.bgColor = clrIn;
	}
}
//
//*-------------------------------------------------------*
//*-- Defilement d'un message dans un champ Input		--*
//*-------------------------------------------------------*
//
function textdefil()
{
	document.form1.deftext.value=msg.substring(position,position+70);
	position++;
	if(position==xlong) position=0;
	setTimeout("textdefil()",100);
}

/*
Effet K2000 sur du texte
SCRIPT EDITE SUR L'EDITEUR JAVASCRIPT
http://www.editeurjavascript.com
*/
function k2000effet()
{
	k2000aff = "";
	for(k2000a=0;k2000a<k2000text.length;k2000a++)
	{
		k2000lettre = k2000text.charAt(k2000a);
		if(k2000a == k2000pos || k2000a == (k2000pos+k2000increment))
			k2000aff += "<FONT COLOR=#FE9E32>"+k2000lettre+"</FONT>";
		else
			k2000aff += k2000lettre;
	}
	document.getElementById("k2000").innerHTML = k2000aff;
	if(k2000pos == k2000text.length)
		k2000increment = -1;
	if(k2000pos == 0 && k2000increment== -1)
		k2000increment = 1;
	k2000pos = k2000pos+k2000increment;
	timer = setTimeout("k2000effet()",30)
}
function disp_k2000effet(k2000text)
{
	if(document.getElementById && document.all)
	{
		document.write('<DIV ID=k2000>'+k2000text+'</DIV>');
		k2000effet()
	}
	else
		document.write(k2000text);
}
