<!--
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_swapImgRestore() { //v3.0
  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_swapImage() { //v3.0
  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) { //v4.01
  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);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function SHLayers() { //v6.0
  var i,p,v,obj,args=SHLayers.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; }
}

function Pop(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}
function Zoom (id) { //v2.0
  Pop('zoom.cfm?id='+id,'','width=480,height=480');
}

function Basket (id,code) { //v2.0
  Pop('basket.cfm?id='+id+'&code='+code,'','width=10,height=10');
}
function goToRando1 () { //v2.0
  document.rando1.submit();
}
function goToRando2 () { //v2.0
  document.rando2.submit();
}

function VenteCondition () { //v2.0
  Pop('pop_ventes.cfm','','width=720,height=560,scrollbars=yes');
}

function CA () { //v2.0
  Pop('pop_casecure.htm','','width=350,height=200');
}

function Valid_Mail () {
var mess = "";
var sep = "";
if (document.command.T1.value == ""){alert(mess=mess+ "Nom ...");}
if (document.command.T1.value == "") {document.command.T1.focus(); return false}
{ if (document.command.T3.value == ""){alert(mess=mess+ "Email ...");document.command.T3.focus(); return false}				
		else if (verif_email(document.command.T3.value) == false){alert("Email errone");return false;}}
return true;
}


function ClientForm () {
var mess = "";
var sep = "\n";
if (document.account.NOM.value == ""){mess=mess+sep+ "Votre nom ...";}
if (document.account.PRENOM.value == ""){mess=mess+sep+ "Votre prenom ...";}
if (document.account.ADRESSE.value == ""){mess=mess+sep+ "Votre adresse ...";}
if (document.account.CP.value == ""){mess=mess+sep+ "Code postal ...";}
if (document.account.VILLE.value == ""){mess=mess+sep+ "Ville ...";}
if (document.account.PAYS_ID.value == "0"){mess=mess+sep+ "Pays ...";}
if (document.account.EMAIL.value == ""){mess=mess+sep+ "Email ...";}
if (document.account.PWD.value == ""){mess=mess+sep+ "Mot de passe ...";}
if (document.account.PWD2.value == ""){mess=mess+sep+ "Confirmation mot de passe ...";}
{ if (document.account.EMAIL.value != "")
	{if (verif_email(document.account.EMAIL.value) == false){alert("Email non conforme"); return false;}}}
if (document.account.NOM.value == "") {document.account.NOM.focus();}
if (mess.length > 0) {alert(mess); return false};
return true;
}

function verif_email(s)
	{			
	var ok = true;			
	if ((s.length < 4)) {ok = false;}			
	var at = s.indexOf('@');
	if (at < 1)	{ok = false;}			
	if (at != s.lastIndexOf('@')) {ok = false;}			
	if ((s.lastIndexOf('.') < (at+2)) || (s.lastIndexOf('.') > (s.length-3)) || (s.lastIndexOf('.') < (s.length-6)))
	{ok = false;}			
	if (
			(s.indexOf(',') != -1) ||(s.indexOf(' ') != -1) ||(s.indexOf(';') != -1) ||(s.indexOf(':') != -1) ||(s.indexOf('?') != -1) ||(s.indexOf('/') != -1) ||(s.indexOf('\\') != -1) ||(s.indexOf('"') != -1) || (s.indexOf("'") != -1) ||(s.indexOf('[') != -1) ||(s.indexOf(']') != -1) ||(s.indexOf('`') != -1) ||(s.indexOf('!') != -1) ||(s.indexOf('#') != -1)	||(s.indexOf('$') != -1) ||(s.indexOf('%') != -1) ||(s.indexOf('^') != -1) ||(s.indexOf('&') != -1) ||(s.indexOf('*') != -1) ||(s.indexOf('(') != -1) ||(s.indexOf(')') != -1) ||(s.indexOf('=') != -1) ||(s.indexOf('+') != -1) ||(s.indexOf('}') != -1) ||(s.indexOf('{') != -1) ||(s.indexOf('|') != -1) ||(s.indexOf('<') != -1) ||(s.indexOf('>') != -1))
		{
		ok = false;
		}
//on récupère le flag
return ok;
}

//-->
