// JavaScript Document
function MnuC(Dest) {
  location.href=Dest;
}

function ChPMnuOvr(o, l) {
  o.className='pmenuon';
  if (l) {
	var obj = MM_findObj(l);
  if (obj) {obj.className='pmenuon';}
	var obj = MM_findObj('t'+l);
  if (obj) {obj.className='pmenuon';}
	MM_changeProp('div'+l,'','style.left',o.offsetLeft+'px','LAYER')
	MM_showHideLayers('div'+l,'','show');
	}
}

function ChPMnuOut(o, l) {
  o.className='pmenuoff';
  if (l) {
	var obj = MM_findObj(l);
  if (obj) {obj.className='pmenuoff';}
	var obj = MM_findObj('t'+l);
  if (obj) {obj.className='pmenuoff';}
	MM_showHideLayers('div'+l,'','hide');
	}
}

function ChMnuOvr(o, l) {
  o.className='menuon';
  if (l) {
	var obj = MM_findObj(l);
  if (obj) {obj.className='menuon';}}
}

function ChMnuOut(o, l) {
  o.className='menuoff';
  if (l) {
	var obj = MM_findObj(l);
  if (obj) {obj.className='menuoff';}}
}

function ChSMnuOvr(o, l) {
  o.className='smenuon';
  if (l) {
	var obj = MM_findObj(l);
  if (obj) {obj.className='smenuon';}}
}

function ChSMnuOut(o, l) {
  o.className='smenuoff';
  if (l) {
	var obj = MM_findObj(l);
  if (obj) {obj.className='smenuoff';}}
}


function MM_showHideLayers() { //v6.0
  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; }
}

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_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_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 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_changeProp(objName,x,theProp,theValue) { //v6.0
  var obj = MM_findObj(objName);
  if (obj && (theProp.indexOf("style.")==-1 || obj.style)){
    if (theValue == true || theValue == false) {
      eval("obj."+theProp+"="+theValue);}
    else eval("obj."+theProp+"='"+theValue+"'");
  }
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function YY_checkform() { //v4.66
//copyright (c)1998,2002 Yaromat.com
  var args = YY_checkform.arguments; var myDot=true; var myV=''; var myErr='';var addErr=false;var myReq;
  for (var i=1; i<args.length;i=i+4){
    if (args[i+1].charAt(0)=='#'){myReq=true; args[i+1]=args[i+1].substring(1);}else{myReq=false}
    var myObj = MM_findObj(args[i].replace(/\[\d+\]/ig,""));
    myV=myObj.value;
    if (myObj.type=='text'||myObj.type=='password'||myObj.type=='hidden'){
      if (myReq&&myObj.value.length==0){addErr=true}
      if ((myV.length>0)&&(args[i+2]==1)){ //fromto
        var myMa=args[i+1].split('_');if(isNaN(myV)||myV<myMa[0]/1||myV > myMa[1]/1){addErr=true}
      } else if ((myV.length>0)&&(args[i+2]==2)){
          var rx=new RegExp("^[\\w\.=-]+@[\\w\\.-]+\\.[a-z]{2,4}$");if(!rx.test(myV))addErr=true;
      } else if ((myV.length>0)&&(args[i+2]==3)){ // date
        var myMa=args[i+1].split("#"); var myAt=myV.match(myMa[0]);
        if(myAt){
          var myD=(myAt[myMa[1]])?myAt[myMa[1]]:1; var myM=myAt[myMa[2]]-1; var myY=myAt[myMa[3]];
          var myDate=new Date(myY,myM,myD);
          if(myDate.getFullYear()!=myY||myDate.getDate()!=myD||myDate.getMonth()!=myM){addErr=true};
        }else{addErr=true}
      } else if ((myV.length>0)&&(args[i+2]==4)){ // time
        var myMa=args[i+1].split("#"); var myAt=myV.match(myMa[0]);if(!myAt){addErr=true}
      } else if (myV.length>0&&args[i+2]==5){ // check this 2
            var myObj1 = MM_findObj(args[i+1].replace(/\[\d+\]/ig,""));
            if(myObj1.length)myObj1=myObj1[args[i+1].replace(/(.*\[)|(\].*)/ig,"")];
            if(!myObj1.checked){addErr=true}
      } else if (myV.length>0&&args[i+2]==6){ // the same
            var myObj1 = MM_findObj(args[i+1]);
            if(myV!=myObj1.value){addErr=true}
      }
    } else
    if (!myObj.type&&myObj.length>0&&myObj[0].type=='radio'){
          var myTest = args[i].match(/(.*)\[(\d+)\].*/i);
          var myObj1=(myObj.length>1)?myObj[myTest[2]]:myObj;
      if (args[i+2]==1&&myObj1&&myObj1.checked&&MM_findObj(args[i+1]).value.length/1==0){addErr=true}
      if (args[i+2]==2){
        var myDot=false;
        for(var j=0;j<myObj.length;j++){myDot=myDot||myObj[j].checked}
        if(!myDot){myErr+='* ' +args[i+3]+'\n'}
      }
    } else if (myObj.type=='checkbox'){
      if(args[i+2]==1&&myObj.checked==false){addErr=true}
      if(args[i+2]==2&&myObj.checked&&MM_findObj(args[i+1]).value.length/1==0){addErr=true}
    } else if (myObj.type=='select-one'||myObj.type=='select-multiple'){
      if(args[i+2]==1&&myObj.selectedIndex/1==0){addErr=true}
    }else if (myObj.type=='textarea'){
      if(myV.length<args[i+1]){addErr=true}
    }
    if (addErr){myErr+='* '+args[i+3]+'\n'; addErr=false}
  }
  if (myErr!=''){alert('The required information is incomplete or contains errors:\t\t\t\t\t\n\n'+myErr)}
  document.MM_returnValue = (myErr=='');
}


function setuser() {
  var user;
  user=GetCookie('instinctexpressuser');
	if (user!=null) MM_changeProp('user','','value',user,'INPUT/TEXT');
}

function getCookieVal (offset) {  
var endstr = document.cookie.indexOf (";", offset);  
if (endstr == -1)    
endstr = document.cookie.length;  
return unescape(document.cookie.substring(offset, endstr));
}
function GetCookie (name) {  
var arg = name + "=";  
var alen = arg.length;  
var clen = document.cookie.length;  
var i = 0;  
while (i < clen) {    
var j = i + alen;    
if (document.cookie.substring(i, j) == arg)      
return getCookieVal (j);    
i = document.cookie.indexOf(" ", i) + 1;    
if (i == 0) break;   
}  
return null;
}

function writemenu() {
var DOM = false;
if (document.all) DOM = true;
if (document.layers) DOM = false;
if (document.getElementById) DOM = true;
if (DOM) {
document.write('<div id="divent" style="position:absolute; z-index:1; overflow: visible; top: 99px; visibility: hidden;" onMouseOver="ChPMnuOvr(this,\'ent\');" onMouseOut="ChPMnuOut(this,\'ent\');"><table border="0" cellpadding="3" cellspacing="0" class="menutable">');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'entap\');" onMouseOut="ChMnuOut(this,\'entap\');" onClick="MnuC(\'entAprop.htm\')"><a href="../ahtm/entAprop.htm" class="menuoff" id="entap">Profile</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'entco\');" onMouseOut="ChMnuOut(this,\'entco\');" onClick="MnuC(\'entCoord.htm\')"><a href="../ahtm/entCoord.htm" class="menuoff" id="entco">Coordinates</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'entvi\');" onMouseOut="ChMnuOut(this,\'entvi\');" onClick="MnuC(\'entVisi.htm\')"><a href="../ahtm/entVisi.htm" class="menuoff" id="entvi">Vision</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'enteq\');" onMouseOut="ChMnuOut(this,\'enteq\');" onClick="MnuC(\'entEqu.htm\')"><a href="../ahtm/entEqu.htm" class="menuoff" id="enteq">Team</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'entpa\');" onMouseOut="ChMnuOut(this,\'entpa\');" onClick="MnuC(\'entPart.htm\')"><a href="../ahtm/entPart.htm" class="menuoff" id="entpa">Alliances</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'entof\');" onMouseOut="ChMnuOut(this,\'entof\');" onClick="MnuC(\'entEmp.htm\')"><a href="../ahtm/entEmp.htm" class="menuoff" id="entof">Employment</a></td></tr></table></div>');
document.write('<div id="divrea" style="position:absolute; z-index:1; overflow: visible; top: 99px; visibility: hidden;" onMouseOver="ChPMnuOvr(this,\'rea\');" onMouseOut="ChPMnuOut(this,\'rea\');"><table border="0" cellpadding="3" cellspacing="0" class="menutable">');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'reaaff\');" onMouseOut="ChMnuOut(this,\'reaaff\');" onClick="MnuC(\'reaAff.htm\')"><a href="../ahtm/reaAff.htm" class="menuoff" id="reaaff">Business</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'reatou\');" onMouseOut="ChMnuOut(this,\'reatou\');" onClick="MnuC(\'reaTou.htm\')"><a href="../ahtm/reaTou.htm" class="menuoff" id="reatou">Tourism and leisure</a></td></tr></table></div>');
document.write('<div id="divsol" style="position:absolute; z-index:1; overflow: visible; top: 99px; visibility: hidden;"  onMouseOver="ChPMnuOvr(this,\'sol\');" onMouseOut="ChPMnuOut(this,\'sol\');"><table border="0" cellpadding="3" cellspacing="0" class="menutable">');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solser\');" onMouseOut="ChMnuOut(this,\'solser\');" onClick="MnuC(\'solServ.htm\')"><a href="../ahtm/solServ.htm" class="menuoff" id="solser" style="font-weight: bold;">Services</a></td></tr>');
document.write('<tr><td nowrap bgcolor="#CCCC66" class="menuligne" height="1"></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solsdev\');" onMouseOut="ChMnuOut(this,\'solsdev\');" onClick="MnuC(\'solSdev.htm\')"><a href="../ahtm/solSdev.htm" class="menuoff" id="solsdev">&nbsp;Developpement</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solsges\');" onMouseOut="ChMnuOut(this,\'solsges\');" onClick="MnuC(\'solSges.htm\')"><a href="../ahtm/solSges.htm" class="menuoff" id="solsges">&nbsp;Management</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solsser\');" onMouseOut="ChMnuOut(this,\'solsser\');" onClick="MnuC(\'solSser.htm\')"><a href="../ahtm/solSser.htm" class="menuoff" id="solsser">&nbsp;Client support</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solsheb\');" onMouseOut="ChMnuOut(this,\'solsheb\');" onClick="MnuC(\'solSheb.htm\')"><a href="../ahtm/solSheb.htm" class="menuoff" id="solsheb">&nbsp;Hosting</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solsfor\');" onMouseOut="ChMnuOut(this,\'solsfor\');" onClick="MnuC(\'solSfor.htm\')"><a href="../ahtm/solSfor.htm" class="menuoff" id="solsfor">&nbsp;Training</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solscon\');" onMouseOut="ChMnuOut(this,\'solscon\');" onClick="MnuC(\'solScon.htm\')"><a href="../ahtm/solScon.htm" class="menuoff" id="solscon">&nbsp;Consultation</a></td></tr>');
document.write('<tr><td nowrap class="menu"><img src="../ahtm/images/shim.gif" width="20" height="1"></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solpro\');" onMouseOut="ChMnuOut(this,\'solpro\');" onClick="MnuC(\'solProd.htm\')"><a href="../ahtm/solProd.htm" class="menuoff" id="solpro" style="font-weight: bold;">Products</a></td></tr>');
document.write('<tr><td nowrap bgcolor="#CCCC66" class="menuligne" height="1"></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solpaut\');" onMouseOut="ChMnuOut(this,\'solpaut\');" onClick="MnuC(\'solPauto.htm\')"><a href="../ahtm/solPauto.htm" class="menuoff" id="solpaut">&nbsp;Automatia</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solpins\');" onMouseOut="ChMnuOut(this,\'solpins\');" onClick="MnuC(\'solPinEx.htm\')"><a href="../ahtm/solPinEx.htm" class="menuoff" id="solpins">&nbsp;Instinct Express</a></td></tr>');
document.write('<tr><td nowrap class="menuoff" onMouseOver="ChMnuOvr(this,\'solpac\');" onMouseOut="ChMnuOut(this,\'solpac\');" onClick="MnuC(\'solPreAcomba.htm\')"><a href="../ahtm/solPreAcomba.htm" class="menuoff" id="solpac">&nbsp;Acomba</a></td></tr></table></div>');
} }
