var PopAttivastd=0;
function _LN_apripopstd(nomepgm,W1,H1,T1,L1)
{   
 if(PopAttivastd) {
  	if(!PopAttivastd.closed) PopAttivastd.close();
  }
 PopAttivastd = window.open(nomepgm,'PopAttivastd','scrollbars=yes,resizable=yes,top='+T1+',left='+L1+',width='+W1+',height='+H1+',status=no,location=no,toolbar=no, menubar=no,copyhistory=no'); 
  setTimeout('PopAttivastd.focus();',250);
}

var PopAttivastdbis=0;
function _LN_apripopstdbis(nomepgm,WW,HH,TT,LL,siono)
{ 
  if(PopAttivastdbis) {
 
  	if(!PopAttivastdbis.closed) PopAttivastdbis.close();
  }
 PopAttivastdbis = window.open(nomepgm,'PopAttivastdbis','scrollbars='+siono+',resizable=yes,top='+TT+',left='+LL+',width='+WW+',height='+HH+',status=no,location=no,toolbar=no, menubar=no,copyhistory=no'); 
  setTimeout('PopAttivastdbis.focus();',250);
}

var PopAttivastdter=0;
function _LN_apripopstdter(nomepgm,WW,HH,TT,LL,siono)
{ 
  if(PopAttivastdter) {
 
  	if(!PopAttivastdter.closed) PopAttivastdter.close();
  }
 PopAttivastdter = window.open(nomepgm,'PopAttivastdter','scrollbars='+siono+',resizable=yes,top='+TT+',left='+LL+',width='+WW+',height='+HH+',status=no,location=no,toolbar=no, menubar=no,copyhistory=no'); 
  setTimeout('PopAttivastdter.focus();',250);
}

var WinAttivaAvo=0;
function _LN_apriwinavo(str,posizione,Larg)
{	
  if(WinAttivaAvo) {
 
  	if(!WinAttivaAvo.closed) WinAttivaAvo.close();
  }
 var W=screen.width/2+340;
 var H=screen.height/2 +100;
 var L=(screen.width-Larg)/2 +80;
 if(posizione=="left") L=0;
 var T=20;
 WinAttivaAvo = window.open(str,'WinAttivaAvo','scrollbars=yes,resizable=yes,top='+T+',left='+L+',width='+W+',height='+H+',screenX='+L+',screenY='+T+',status=no, location=no, toolbar=no, menubar=no'); 
  setTimeout('WinAttivaAvo.focus();',250);
}

var WinAttivaFiglio=0;
function _LN_apriwinfiglio(str,posizione,Larg)
{	
  if(WinAttivaFiglio) {
 
  	if(!WinAttivaFiglio.closed) WinAttivaFiglio.close();
  }
 var W=screen.width/2+340;
 var H=screen.height/2 +100;
 var L=(screen.width-Larg)/2 +80;
 if(posizione=="left") L=0;
 var T=150;
 WinAttivaFiglio = window.open(str,'WinAttivaFiglio','scrollbars=yes,resizable=yes,top='+T+',left='+L+',width='+W+',height='+H+',screenX='+L+',screenY='+T+',status=no, location=no, toolbar=nnnno, menubar=no'); 
  setTimeout('WinAttivaFiglio.focus();',250);
}

var WinAttivaPadre=0;
function _LN_apriwinpadre(str,posizione,Larg) {	
  if(WinAttivaPadre) {
  	if(!WinAttivaPadre.closed) WinAttivaPadre.close();
  }
 var W=screen.width/2+340;
 var H=screen.height/2;
 var L=0;
	if(posizione=="left") L=0;
	var T=screen.height/2 -90;
	WinAttivaPadre =window.open(str,'WinAttivaPadre','scrollbars=yes,resizable=yes,top='+T+',left='+L+',width='+W+',height='+H+',status=yes, location=no, toolbar=no, menubar=no, copyhistory=no'); 
 	 setTimeout('WinAttivaPadre.focus();',250);
}

var WinAttivaTerzi=0;
function _LN_apriwinterzi(str)
{
  if(WinAttivaTerzi) {
 
  	if(!WinAttivaTerzi.closed) WinAttivaTerzi.close();
  }
 var W=770  +(screen.width-770)/2 ;
 var H=screen.height/2 +40;
 var L=0;
 var T=0;
 
 WinAttivaTerzi = window.open(str,'WinAttivaTerzi','scrollbars=yes,resizable=yes,top='+T+',left='+L+',width=800,height='+H+',status=no,location=no,toolbar=no, menubar=no,copyhistory=no'); 
  setTimeout('WinAttivaTerzi.focus();',250);
}


function  _LN_checkcancel(LNtesto) {
		if (confirm(LNtesto))
			return true;
		else
			return false;			
}


<!--
function  _LN_checkdate(object_name,object_value) {
   if (_LN_checkeurodate(object_value) == false)
   	{commento='Data';
		if(object_name){commento=object_name}
		alert("Il campo " +commento +" non e' valido");
      return false;
	  }
}

function  _LN_checkdatetime(object_name,object_value) {
   if (_LN_checkeurodate(object_value) == false)
   	{commento='Data';
		if(object_name){commento=object_name}
		alert("Il campo " +commento +" e' invalido");
      return false;
	  }
  
  if (_LN_checktime(object_value) == false)
   	{commento='Orario ';
		if(object_name){commento=object_name}
		alert("Il campo " +commento +" e' invalido");
      return false;
	  }
}

function _LN_checkday(checkYear, checkMonth, checkDay)
{
	maxDay = 31;

	if (checkMonth == 4 || checkMonth == 6 ||
		checkMonth == 9 || checkMonth == 11)
		maxDay = 30;
	else if (checkMonth == 2)
	{
		if (checkYear % 4 > 0)
			maxDay =28;
		else if (checkYear % 100 == 0 && checkYear % 400 > 0)
			maxDay = 28;
		else
			maxDay = 29;
	}

	return _LN_checkrange(checkDay, 1, maxDay);
}

function _LN_checkeurodate(object_value)
{  	
	if (object_value.length == 0)
		return true;
	isplit = object_value.indexOf('/');
	if (isplit == -1)
		isplit = object_value.indexOf('.');
	if (isplit == -1 || isplit == object_value.length)
		return false;
	sDay = object_value.substring(0, isplit);
	monthSplit = isplit + 1;
	isplit = object_value.indexOf('/', monthSplit);
	if (isplit == -1)
		isplit = object_value.indexOf('.', monthSplit);
	if (isplit == -1 ||  (isplit + 1 )  == object_value.length)
		return false;
	sMonth = object_value.substring((sDay.length + 1), isplit);
	sYear = object_value.substring((isplit + 1),(isplit+5));
	
	 if (!_LN_checkinteger(sMonth))
		{ return false;}
	else
	if (!_LN_checkrange(sYear, 2004, 3000))
		{return false;}
	else
	if (!_LN_checkrange(sMonth, 1, 12))
		{return false;}
	else
	if (!_LN_checkinteger(sYear))
		{ return false;}
	else
	if (!_LN_checkrange(sYear, 0, null))
		{ return false;}
	else
	if (!_LN_checkinteger(sDay))
		{ return false;}
	else
	{
	if (!_LN_checkday(sYear, sMonth, sDay))
		{ return false;}
	else
		{ return true;}
	}
}
function  _LN_checkFormDomande(_LN_this)
{ 
	if(_LN_this.NickName)
	{
		if  (!_LN_hasValue(_LN_this.NickName, "TEXT" ))
		{
			if  (!_LN_onError(_LN_this, _LN_this.NickName, _LN_this.NickName.value, "Il Nick name e' richiesto"))
			{
				return false;
			}
		}

		if  (!_LN_CheckLunghezzaCampo(_LN_this, _LN_this.NickName.name, _LN_this.NickName.value,'4','4'))
		{
			if  (!_LN_onError(_LN_this, _LN_this.NickName, _LN_this.NickName.value, "VUOTO"))
			{
				return false;
			}
		}
	}
	
	if(_LN_this.Destinatario)
	{
		if  (!_LN_hasValue(_LN_this.Destinatario, "TEXT" ))
		{
			if  (!_LN_onError(_LN_this, _LN_this.Destinatario, _LN_this.Destinatario.value, "La email del destinatario e' richiesta"))
				{return false;}
		}
	
		if  (!_LN_checkiscemail(_LN_this, _LN_this.Destinatario.name, _LN_this.Destinatario.value))
		{
			if  (!_LN_onError(_LN_this, _LN_this.Destinatario, _LN_this.Destinatario.value, "VUOTO"))
			{return false;}
		}
	}
	
	if(_LN_this.Mittente)
	{
		if  (!_LN_hasValue(_LN_this.Mittente, "TEXT" ))
		{
			if  (!_LN_onError(_LN_this, _LN_this.Mittente, _LN_this.Mittente.value, "La email del Mittente e' richiesta"))
				{return false;}
		}
	
		if  (!_LN_checkiscemail(_LN_this, _LN_this.Mittente.name, _LN_this.Mittente.value))
		{
			if  (!_LN_onError(_LN_this, _LN_this.Mittente, _LN_this.Mittente.value, "VUOTO"))
			{return false;}
		}
	}
	if(_LN_this.EMail)
	{ 	if(_LN_this.EMail.value =='') return true;
		if  (!_LN_hasValue(_LN_this.EMail, "TEXT" ))
		{
			if  (!_LN_onError(_LN_this, _LN_this.EMail, _LN_this.EMail.value, "La email e' richiesta"))
				{return false;}
		}
	
		if  (!_LN_checkiscemail(_LN_this, _LN_this.EMail.name, _LN_this.EMail.value))
		{
			if  (!_LN_onError(_LN_this, _LN_this.EMail, _LN_this.EMail.value, "VUOTO"))
			{return false;}
		}
	}
	

	if(_LN_this.Oggettoargomento)
	{
		if  (!_LN_hasValue(_LN_this.Oggettoargomento, "TEXT" ))
		{
			if  (!_LN_onError(_LN_this, _LN_this.Oggettoargomento, _LN_this.Oggettoargomento.value, "Il campo Argomento o Domanda e' richiesto"))
			{
				return false;
			}
		}
	
		if  (!_LN_CheckLunghezzaCampo(_LN_this, 'Argomento o Domanda' , _LN_this.Oggettoargomento.value,'4','4'))
		{
			if  (!_LN_onError(_LN_this, 'Oggetto Argomento', _LN_this.Oggettoargomento.value, "VUOTO"))
			{
				return false;
			}
		}	
	}
	
	if(_LN_this.Oggetto)
	{
		if  (!_LN_hasValue(_LN_this.Oggetto, "TEXT" ))
		{
			if  (!_LN_onError(_LN_this, _LN_this.Oggetto, _LN_this.Oggetto.value, "Il campo Oggetto e' richiesto"))
			{
				return false;
			}
		}
	
		if  (!_LN_CheckLunghezzaCampo(_LN_this, 'Oggetto' , _LN_this.Oggetto.value,'4','4'))
		{
			if  (!_LN_onError(_LN_this, 'Oggetto', _LN_this.Oggetto.value, "VUOTO"))
			{
				return false;
			}
		}	
	}

	return true;
}

function  _LN_checkFormIsc(_LN_this)
{
	if  (!_LN_hasValue(_LN_this.Password, "PASSWORD" ))
	{
		if  (!_LN_onError(_LN_this, _LN_this.Password, _LN_this.Password.value, "La password e' richiesta"))
		{
			return false;
		}
	}

	if  (!_LN_checkiscpassword(_LN_this, _LN_this.Password, _LN_this.Password.value))
	{
		if  (!_LN_onError(_LN_this, _LN_this.Password, _LN_this.Password.value, "VUOTO"))
		{
			return false;
		}
	}
	
	if  (!_LN_hasValue(_LN_this.EMail, "TEXT" ))
	{
		if  (!_LN_onError(_LN_this, _LN_this.EMail, _LN_this.EMail.value, "La email e' richiesta"))
		{
			return false;
		}
	}

	if  (!_LN_checkiscemail(_LN_this, _LN_this.EMail.name, _LN_this.EMail.value))
	{
		if  (!_LN_onError(_LN_this, _LN_this.EMail, _LN_this.EMail.value, "VUOTO"))
		{
			return false;
		}
	}

	if  (!_LN_hasValue(_LN_this.UserID, "TEXT" ))
	{
		if  (!_LN_onError(_LN_this, _LN_this.UserID, _LN_this.UserID.value, "La userid  e' richiesta"))
		{
			return false;
		}
	}

	if  (!_LN_checkiscuser(_LN_this, _LN_this.UserID, _LN_this.UserID.value))
	{
		if  (!_LN_onError(_LN_this, _LN_this.UserID, _LN_this.UserID.value, "VUOTO"))
		{
			return false;
		}
	}	

	if  (!_LN_hasValue(_LN_this.IDProvincia, "SELECT" ))
	{
		if  (!_LN_onError(_LN_this, _LN_this.IDProvincia, _LN_this.IDProvincia.value, "La provincia  e' richiesta"))
		{
			return false;
		}
	}

	return true;
}

function _LN_checkinteger(object_value)
{ 
	if (object_value.length == 0)
	return true;
	var decimal_format = ".";
	var check_char = object_value.indexOf(decimal_format);
	if (check_char == -1)
		{ 
		return _LN_checknumber(object_value);}

	else
		{ 
		return false;}
}

function  _LN_checkiscemail(oForm, oTag, EMail)
{ 
	commento='';
	if(oTag){
		if(oTag !="EMail"){commento="del " +oTag;} 
	}
   if (EMail.length < 6 ||  EMail.length > 50 ) {
		if  (!_LN_onError(oForm, oForm.EMail, EMail, "La email " +commento +" deve  essere fornita e deve avere minimo 6 e massimo 50 caratteri")) {
			return false;
		}
	}
	str= EMail;
	filter=/^(\w+(?:\.\w+)*)@((?:\w+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/
	if (!filter.test(str))
	{
		if  (!_LN_onError(oForm, oForm.EMail, EMail,'Fornire un indirizzo email '  +commento +' valido' )) 
		{
			return false;
		}
	}
	invalidaddress=new Array()
	invalidaddress[0]="hotmail22"
	invalidaddress[1]="rocketmail22"
	invalidaddress[2]="zdnetmail22"
	invalidcheck=0;	
	tempstring=str.split("@")
	tempstring=tempstring[1].split(".")
	for (i=0; i <invalidaddress.length;i++){
		if (tempstring[0]==invalidaddress[i])
		invalidcheck=1
	}
	if (invalidcheck==1){
	if  (!_LN_onError(oForm, oForm.EMail, EMail, "Fornire un indirizzo email " +commento +" consentito")) {
	return false;
		}
	}
	return true;
}

function  _LN_checkiscpassword(oForm, oTag, password)
{ 
	if(password =="ac" )
		return true;
	else {
		if  ( password.length < 6  ||  password.length > 12   )  {
			if  (!_LN_onError(oForm, oForm.password, password, "La passsword deve  essere fornita e deve avere minimo 6 e massimo 12 caratteri")) {
			return false;
			}
		}
	}
	digitcheck = new  Array(62);
	digitcheck[0]='A';
	digitcheck[1]='B';
	digitcheck[2]='C';
	digitcheck[3]='D';
	digitcheck[4]='E';
	digitcheck[5]='F';	
	digitcheck[6]='G';
	digitcheck[7]='H';
	digitcheck[8]='I';
	digitcheck[9]='J';
	digitcheck[10]='K';
	digitcheck[11]='L';	
	digitcheck[12]='M';
	digitcheck[13]='N';
	digitcheck[14]='O';	
	digitcheck[15]='P';
	digitcheck[16]='Q';
	digitcheck[17]='R';
	digitcheck[18]='S';
	digitcheck[19]='T';
	digitcheck[20]='U';	
	digitcheck[21]='V';
	digitcheck[22]='W';
	digitcheck[23]='X';
	digitcheck[24]='Y';
	digitcheck[25]='Z';
	digitcheck[26]='a';
	digitcheck[27]='b';
	digitcheck[28]='c';
	digitcheck[29]='d';
	digitcheck[30]='e';
	digitcheck[31]='f';	
	digitcheck[32]='g';
	digitcheck[33]='h';
	digitcheck[34]='i';
	digitcheck[35]='j';	
	digitcheck[36]='k';
	digitcheck[37]='l';	
	digitcheck[38]='m';
	digitcheck[39]='n';
	digitcheck[40]='o';	
	digitcheck[41]='p';
	digitcheck[42]='q';
	digitcheck[43]='r';
	digitcheck[44]='s';
	digitcheck[45]='t';
	digitcheck[46]='u';	
	digitcheck[47]='v';
	digitcheck[48]='w';
	digitcheck[59]='x';
	digitcheck[50]='y';
	digitcheck[51]='z';
	digitcheck[52]='0';
	digitcheck[53]='1';
	digitcheck[54]='2';
	digitcheck[55]='3';
	digitcheck[56]='4';
	digitcheck[57]='5' ;
	digitcheck[58]='6';
	digitcheck[59]='7';
	digitcheck[60]='8';
	digitcheck[61]='9';
	for ( var i1=0; i1 < password.length; i1++) {
		check=false; 
		for (var i2=0; i2 <=61; i2++) {
		
			if ( password.charAt(i1) == digitcheck[i2] ) {
				check=true
				break;
			}
		}	
		if (!check){
			alert (" La password deve essere formata solo da lettere e numeri. Quella fornita contiene un carattere illegale alla posizione " +i1 );
			break;
			return false;
		}
	}
	return true;
}

function  _LN_checkiscuser(oForm, oTag, userid)
{
   if(userid == "ac" )
   	return true;
   else
   {
		if (userid.length < 6 ||  userid.length > 20  ) { 
			if  (!_LN_onError(oForm, oForm.userid, userid, "La login deve  essere fornita e deve avere minimo 6 e massimo 20 caratteri")) 
			{
				return false;
			}
		}
		if  (userid == oForm.Password.value) {
			if  (!_LN_onError(oForm, oForm.userid, userid, "La login e' uguale alla password cambiare una delle due "))
			{
				return false;
			}
		}
		return true;
	}	
}


function _LN_CheckLunghezzaCampo(oForm, oTag, campo,zeroinp,minimoinp)
{ 
	var zero=0;
	var minimo=4;
	if(zeroinp)zero=zeroinp;
 	if(minimoinp)minimo=minimoinp;
  	if (campo.length == zero)return true;
	if (campo.length  < minimo) 
	
	{
		if  (!_LN_onError(oForm, oForm.campo, campo, "il campo : " +oTag +" deve avere minimo di " +minimo +" caratteri")) 
		{
			return false;
		}
	}
	else 
	    return true;
}

function _LN_checknumber(object_value)
{ 	

	if (object_value.length == 0)
		return true;
	var start_format = " .+-0123456789";
	var number_format = " .0123456789";
	var check_char;
	var decimal = false;
	var trailing_blank = false;
	var digits = false;

	check_char = start_format.indexOf(object_value.charAt(0));
	if (check_char == 1)
		decimal = true;
	else if (check_char < 1)
		return false;
	for (var i = 1; i < object_value.length; i++)
	{
		check_char = number_format.indexOf(object_value.charAt(i));
		if (check_char < 0)
			return false;
		else if (check_char == 1)
		{
			if (decimal)
				return false;
			else
				decimal = true;
		}
		else if (check_char == 0)
		{
			if (decimal || digits)	
				trailing_blank = true;
		}
		else if (trailing_blank)
			return false;
		else
			digits = true;
	}	
	return true
}

function _LN_checknumberphone(oForm, oTag,object_value)
{ if(object_value.length == 0) return false;
	digitcheck = new  Array(11);
	digitcheck[0]='.';
	digitcheck[1]='1';
	digitcheck[2]='2';
	digitcheck[3]='3';
	digitcheck[4]='4';
	digitcheck[5]='5';	
	digitcheck[6]='6';
	digitcheck[7]='7';
	digitcheck[8]='8';
	digitcheck[9]='9';
	digitcheck[10]='0';
	for ( var i1=0; i1 < object_value.length; i1++) 
	{
		check=false; 
		for (var i2=0; i2 <=11; i2++) 
		{
			if ( object_value.charAt(i1) == digitcheck[i2] )
			{
				check=true;
				break;
			}
		}	
		if (!check)
		{
			break;
		}
	}
	if (!check){ 
	alert("Numero di telefono errato");
	
	return false; }else return true;
}

function _LN_checkrange(object_value, min_value, max_value)
{ 
	if (object_value.length == 0)
		{ return false;}

	if (!_LN_checknumber(object_value))
		return false;
	else
		return (_LN_numberrange((eval(object_value)), min_value, max_value));

	return true;
}

function _LN_checktime(object_value)
{
	if (object_value.length == 0)
		return true;

	isplit = object_value.indexOf(':');
	if (isplit == -1 || isplit == object_value.length)
		return false;
	sHour = object_value.substring(11, isplit);
	iminute = object_value.indexOf(':', isplit + 1);
	if (iminute == -1 || iminute == object_value.length)
		sMin = object_value.substring((sHour.length + 12));
	else
		sMin = object_value.substring((sHour.length + 12), iminute);
	
	if (!_LN_checkinteger(sHour))
		{ return false;}
	else if (!_LN_checkrange(sHour, 0, 23))
		{ return false;}
	
	if (!_LN_checkinteger(sMin))
		{ return false;}
	else
	if (!_LN_checkrange(sMin, 0, 59))
		{ return false;}
	if (iminute != -1)
	{ 
		sSec = object_value.substring(iminute + 1);
		if (!_LN_checkinteger(sSec))
			return false;
		else if (!_LN_checkrange(sSec, 0, 59))
			return false;	
	}

	return true;
}

function _LN_hasValue(obj, obj_type)
{
	if (obj_type == "TEXT" || obj_type == "PASSWORD")
	{
		if (obj.value.length == 0) 
	  		return false;
		else 
	  		return true;
	}
	else if (obj_type == "SELECT")
	{
		for (i=1; i < obj.length; i++)
		{
			if (obj.options[i].selected)
				return true;
		}
	   	return false;	
	}
	else if (obj_type == "SINGLE_VALUE_RADIO" || obj_type == "SINGLE_VALUE_CHECKBOX")
	{
		if (obj.checked)
			return true;
		else
	   		return false;	
	}
	else if (obj_type == "RADIO" || obj_type == "CHECKBOX")
	{
		for (i=0; i < obj.length; i++)
		{
			if (obj[i].checked)
				return true;
		}
	   	return false;	
	}
}

function _LN_numberrange(object_value, min_value, max_value)
{
	if (min_value != null)
	{
		if (object_value < min_value)
			return false;
	}

	if (max_value != null)
	{
		if (object_value > max_value)
			return false;
	}

	return true;
}

function _LN_onError(form_object, input_object, object_value, error_message)
{
	if(error_message != "VUOTO"){
		alert(error_message);
	}
	return false;	
}


function  _LN_openchk(pgm) {
	cartella = location.pathname;
	L=screen.width/2-100;
	H=screen.height/2-60;
	H=2000;
	opzioni = 'width=196,height=100,top='+H+',left='+L+',scrollbars=no,resizable=no,status=no, location=no, toolbar=no, menubar=no';
	window.open('../' +pgm+'?'+cartella,'',opzioni);
}

ns4 = (document.layers)? true:false
ie4 = (document.all)? true:false

function _LN_UTI_PrintIt(){
	
	if(ie4 || ns4){
		self.print();
	} else {
		alert('Ora scegli \'stampa\' nel menu \'File\'.')
		}
}

function _LN_UTI_salva(numero) { 
	if (document.all) {   
	document.execCommand('SaveAs','1','Editoriale'+numero +'.txt'); 
	}
	else {  
	alert('Con il tuo Browser non funziona.');    
	} 
} 


function _LN_zoom(dim1, dim2){
	if(dim1){ 
		if((document.images["PictureBox"].width < 0.10*oW && dim1  <0 )|| (document.images["PictureBox"].width > 2*oW && dim1 >0 )) // se si arriva al 10% del vaolre non si fa nulla
		{ 
			document.images["PictureBox"].width  += 0;
			document.images["PictureBox"].height += 0;
		}
		else { 
			document.images["PictureBox"].width  += dim1;
			document.images["PictureBox"].height += dim2;
			
		}
	} 
	else { // se manca dim1  è stato premuto il tasto per riportarsi ai valori inziali
		document.images["PictureBox"].width   = oW;
		document.images["PictureBox"].height  = oH;
	}
}






<!--

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_swapimg() { //v3.0
	  var i,j=0,x,a=MM_swapimg.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_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];}
}

