// File incluso per il funzionamento del menu e delle finestre pop-up

isamap = new Object();
isamap[0] = "_df"
isamap[1] = "_ov"
isamap[2] = "_ot"
isamap[3] = "_dn"

function isimgact(id, act)
{
	if(document.images) document.images[id].src = eval( "roll." + id + isamap[act] + ".src");
}

if (document.images) { // ensure browser can do JavaScript rollovers.
roll = new Object();
roll.rdk_df = new Image();
roll.rdk_df.src = "../shared_images/but_rdk.gif";

roll.rdk_ov = new Image();
roll.rdk_ov.src = "../shared_images/but_rdk02.gif";

roll.uomo_df = new Image();
roll.uomo_df.src = "../shared_images/menu/but_uomo.gif";

roll.uomo_ov = new Image();
roll.uomo_ov.src = "../shared_images/menu/but_uomo02.gif";

roll.donna_df = new Image();
roll.donna_df.src = "../shared_images/menu/but_donna.gif";

roll.donna_ov = new Image();
roll.donna_ov.src = "../shared_images/menu/but_donna02.gif";

roll.bambino_df = new Image();
roll.bambino_df.src = "../shared_images/menu/but_bambino.gif";

roll.bambino_ov = new Image();
roll.bambino_ov.src = "../shared_images/menu/but_bambino02.gif";

}

function openWindow(url) {

     popUpWin =
window.open(url,'product','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=285,height=313,screenX=110,screenY=10,left=110,top=10');

      if (!popUpWin.focus()) {
         popUpWin.focus();
      }

   popUpWin.location.href = url;
   popUpWin.opener = self
  }

function openWindowGift(url) {
		
    	popUpWin = window.open(url,'giftwrap','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=250,height=350,screenX=110,screenY=10,left=110,top=10');
		
}

function openWindowTell2(url) {
		
    	popUpWin = window.open(url,'tell','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=420,height=420,screenX=110,screenY=10,left=110,top=10');
}

function openWindowTaglie(url) {
		
    	popUpWin = window.open(url,'taglie','toolbar=0,location=0,scrollbars=1,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=580,height=440,screenX=110,screenY=10,left=110,top=10');
}

function openWindowValuta(url) {

     popUpWin = window.open(url,'valuta','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=500,height=560,screenX=110,screenY=10,left=110,top=10');
  }

function openWindowTell(url) {

     popUpWin = window.open(url,'tell','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=430,height=550,screenX=110,screenY=10,left=110,top=10');
  }

function openWindowDettagli(url) {

     popUpWin = window.open(url,'dettagli','toolbar=0,location=0,directories=0,scrollbars=1,status=0,menubar=0,scrollbars=1,resizable=1,width=750,height=400,screenX=110,screenY=10,left=20,top=100');
  }

function WinOpen(url,name,features) {
	popWin = window.open(url,name,features);
}

// Apre un popup (dimensioni parametrizzate)
function openWindowGeneral(l, t, w, h, URL, nome, scroll, redim) {
   var windowprops = "location=no,scrollbars=" + scroll + ",menubars=no,toolbars=no,resizable=" + redim +  ",left=" + l + ",top=" + t + ",width=" + w + ",height=" + h;
	 popUpWin = window.open(URL,nome,windowprops);
}
/* Funzione per il pop-up */
function popUpWin2(url,width,height,scroll) {

	parString= "toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=" + scroll + ",resizable=0,width=" + width + ",height=" + height + ",screenX=200,screenY=100,left=200,top=100"
    window.open(url,"popUpWin",parString);
}
function popUpWin(url,width,height,scroll) {

	parString= "toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=" + scroll + ",resizable=0,width=" + width + ",height=" + height + ",screenX=200,screenY=100,left=200,top=100"
    window.open(url,"popUpWin",parString);
}
function openWindowIMG(l, t, w, h,URL, nome, scroll, redim) 
{
var windowprops = "location=no,scrollbars=" + scroll + ",menubars=no,toolbars=no,statusbar=yes,resizable=" + redim +  ",left=" + l + ",top=" + t + ",width=" + w + ",height=" + h;
popUpWin = window.open(URL,nome,windowprops);
}
function rtrim (s)
{
	var rpatt = new RegExp( "^(.*[^ ]) *$" );
	var parse = s.match( rpatt );
	return parse;
}
//-->
