function MM_displayStatusMsg(msgStr) { //v1.0
  status=msgStr;
  document.MM_returnValue = true;
}

function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}

function refreshFrames(page_main) {
	window.top.location.href="index_fr_left.asp?contentValue="+page_main+"&tagContent=1&menuValue=1&valueScroll=1";
	//window.top.menu.location="menu_left.htm";
	//window.top.content.location=page_main;
}

function left_popup(theURL,winName,features) {
 	facom_left_popup= window.open(theURL,winName,features+',left=20,top=20');
}


function refreshFrames2(page_main) {
	window.top.menu.location="menu_left.htm";
	window.top.content.location=page_main;
}



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 displayPopup(url, winName, winWidth, winHeight, features) {
	var winTop = (screen.height - winHeight) / 2;
	var winLeft = (screen.width - winWidth) / 2;

	window.open(url, winName, features + ',width=' + winWidth + ',height=' + winHeight + ',top=' + winTop + ', left=' + winLeft);
}




function twAller(_url,_cadre,_target) {
  if (_cadre) {
    parent._cadre.location.href = _url;
  } else if (_target) {
    _target = window.open(_url,_target);
  } else {
    window.location.href = _url;
  }
}


function twPopUp(_url,_nom,_larg,_haut,_defil) {
var op_scroll = _defil;
var op_wid = _larg;
var op_heigh = _haut;
var op_tool = 0;
var op_loc_box = 0
var op_dir = 0;
var op_stat = 0;
var op_menu = 0;
var op_resize = 0;
var options = "toolbar="+ op_tool +",location="+ op_loc_box +",directories="
+ op_dir +",status="+ op_stat +",menubar="+ op_menu +",scrollbars="
+ op_scroll +",resizable=" + op_resize +",width=" + op_wid +",height="+ op_heigh;
var wNom = window.open(_url, _nom, options);
if(_nom.focus){_nom.focus();}
}


function refreshFrames(page_main) {
	window.top.location.href="index_fr_left.asp?contentValue="+page_main+"&tagContent=1&menuValue=1&valueScroll=1";
	//window.top.menu.location="menu_left.htm";
	//window.top.content.location=page_main;
}

function left_popup(theURL,winName,features) {
 	facom_left_popup= window.open(theURL,winName,features+',left=20,top=20');
}

function refreshFrames2(page_main) {
	window.top.menu.location="menu_left.htm";
	window.top.content.location=page_main;
}



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 displayPopup(url, winName, winWidth, winHeight, features) {
	var winTop = (screen.height - winHeight) / 2;
	var winLeft = (screen.width - winWidth) / 2;

	window.open(url, winName, features + ',width=' + winWidth + ',height=' + winHeight + ',top=' + winTop + ', left=' + winLeft);
}



function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);




function popup() {
        popwindow = window.open(popwindowURL, "FFFFFFFFFF", tools);


}

function movewindow() {

popwindow.moveTo(popwindowright,popwindowtop)

}
function windopen(page,taille)
{
	fenetre=window.open(page,"image",taille)

}
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function refreshFrames(page_main) {
	window.top.location.href="index_fr_left.asp?contentValue="+page_main+"&tagContent=1&menuValue=1&valueScroll=1";
	//window.top.menu.location="menu_left.htm";
	//window.top.content.location=page_main;
}

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_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

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_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_displayStatusMsg(msgStr) { //v1.0
  status=msgStr;
  document.MM_returnValue = true;
}

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 windopen(page,taille)
{
	fenetre=window.open(page,"image",taille)

}




function preloadProductsImg() {
	for (i = 0; i < productsName.length; i++) {
		productName = productsName[i];

		// photo
		MM_preloadImages(imgPath + productName + '.gif', 'photo_' + productName);
		// text
		MM_preloadImages(imgPath + 'text_' + productName + '.gif', 'text_' + productName);
		// roll
		MM_preloadImages(imgPath + 'v_' + productName + '_on.gif', 'roll_' + productName);
	}
}

function displayProduct(id) {
	productName = productsName[id];

	// hide old product
	if (currentProductId != undefined ) {
		oldProductName = productsName[currentProductId];
		pictoImgName = 'roll_' + oldProductName;
		pictoImgPath = imgPath + 'v_' + oldProductName + '_off.gif';

		document.images[pictoImgName].src = pictoImgPath;
	}

	// display new product
	photoImgPath = imgPath + productName + '.gif';

	textImgPath = imgPath + 'text_' + productName + '.gif';

	pictoImgName = 'roll_' + productName;
	pictoImgPath = imgPath + 'v_' + productName + '_on.gif';

	document.images[pictoImgName].src = pictoImgPath;
	document.images['productPhoto'].src = photoImgPath;
	document.images['productText'].src = textImgPath;
		// set new id
	currentProductId = id;

}

function rollOverPicto(id) {
	productName = productsName[id];

	pictoImgName = 'roll_' + productName;
	pictoImgPath = imgPath + 'v_' + productName + '_on.gif';

	document.images[pictoImgName].src = pictoImgPath;

}

function rollOutPicto(id) {
	if (id != currentProductId) {
		productName = productsName[id];

		pictoImgName = 'roll_' + productName;
		pictoImgPath = imgPath + 'v_' + productName + '_off.gif';

		document.images[pictoImgName].src = pictoImgPath;
	}
}


function displayPopup(url, winName, winWidth, winHeight, features) {
	var winTop = (screen.height - winHeight) / 2;
	var winLeft = (screen.width - winWidth) / 2;

	window.open(url, winName, features + ',width=' + winWidth + ',height=' + winHeight + ',top=' + winTop + ', left=' + winLeft);
}


function gotoProduct() {
  switch(currentProductId) {
    case 0:
      width=900;
      height=900;
    break;

    break;
    case 3:
      width=740;
      height=550;
    break;
   case 4:
      width=840;
      height=660;
    break;
    default:
      width=800;
      height=760;
  }


	popupURL = productsPath + productsLocation[currentProductId];

	displayPopup(popupURL, 'popup' + currentProductId, width, height, 'scrollbars=yes');
}

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_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_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_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}
//-->


