/*function Delete_Cookie( name, path, domain ) {
if ( Get_Cookie( name ) ) document.cookie = name + "=" +
( ( path ) ? ";path=" + path : "") +
( ( domain ) ? ";domain=" + domain : "" ) +
";expires=Thu, 01-Jan-1970 00:00:01 GMT";
}
*/
function Set_Cookie( name, value, expires, path, domain, secure ) 
{
//delete_Cookie("musica","/gestione",""); 

// set time, it's in milliseconds
var today = new Date();
today.setTime( today.getTime() );

/*
if the expires variable is set, make the correct 
expires time, the current script below will set 
it for x number of days, to make it for hours, 
delete * 24, for minutes, delete * 60 * 24
*/
if ( expires )
{
expires = expires * 1000 * 60 * 60 * 24;
}
var expires_date = new Date( today.getTime() + (expires) );

document.cookie = name + "=" +escape( value ) +
( ( expires ) ? ";expires=" + expires_date.toGMTString() : "" ) + 
( ( path ) ? ";path=" + path : "" ) + 
( ( domain ) ? ";domain=" + domain : "" ) +
( ( secure ) ? ";secure" : "" );
}
	 

function musicaSi(){
parent.musica.location.href="http://www.villaariston.it/musica.htm"
 
Set_Cookie("musica","si","","/gestione","","")
//document.cookie = "musica=si"
 

}
 
 function musica( ) 
{
name="musica"
path="/gestione"
value="si";
 expires="";
secure=""
domain="";
document.cookie = name + "=" +escape( value ) +
( ( expires ) ? ";expires=" + expires_date.toGMTString() : "" ) + 
( ( path ) ? ";path=" + path : "" ) + 
( ( domain ) ? ";domain=" + domain : "" ) +
( ( secure ) ? ";secure" : "" );
}
	function creamusica(musica_da_car){
	//alert(musica_da_car)
		//
		
		name="musica"
path="/gestione"
value="si";
 expires="";
secure=""
domain="";
document.cookie = name + "=" +escape( value ) +
( ( expires ) ? ";expires=" + expires_date.toGMTString() : "" ) + 
( ( path ) ? ";path=" + path : "" ) + 
( ( domain ) ? ";domain=" + domain : "" ) +
( ( secure ) ? ";secure" : "" );
		
		//
			 parent.musica.document.writeln("<head>"+
        "<title>detail</title>"+
        "</head>"+

"<body bgcolor='#000000' marginwidth='0' marginheight='0' leftmargin='0' topmargin='0'>"+
"<body background='/images/sfondo_vuoto.gif' marginwidth='0' marginheight='0' leftmargin='0' topmargin='0' onLoad='musica()'>"+
"<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#3,0,0,0' width='5' height='32'>"+
  "  <param name='src' value='/musica_remota.swf?musica_da_caricare="+musica_da_car+"'>"+
    "<embed src='/musica_remota.swf?musica_da_caricare="+musica_da_car+"' pluginspage='http://www.macromedia.com/shockwave/download/' type='application/x-shockwave-flash' width='5' height='32'>"+
   " </embed>"+
  "</object>"+

"</body>");
parent.musica.document.close()

}


 
 
 
 
function musicaNo(){
 
parent.musica.location.href="http://www.villaariston.it/musica_no.htm"
 
Set_Cookie("musica","no","","/gestione","","")
//document.cookie = "musica=no"
 

}
 

	
	
	function checkcontatto( lingua){
              if (document.result.giorno_arrivo.value.length == 0 ||
                   document.result.giorno_partenza.value.length == 0 ||
                   document.result.email.value.length == 0     ||
                   document.result.Sig.value.length == 0
                    ) {
                   if (lingua == "ITA") {
                       alert ("        Attenzione!\n Occorre specificare almeno il nome, l'email, la data di arrivo e di partenza.");
                   } else {
                       alert ("        Warning|\n Name, email , Arrival date and Departure date are needed");
                   }
             } else {
                document.result.submit();
             }

        }
	
	function creazoom(foto){
	
	var newwin;


var l = screen.width;
var a = screen.height;

	//function crea(variabile,dim_x,dim_y){
	
	dim_x=640;
	dim_y=480;
	
	
	var wi = (l-dim_x)/2;
	var he = (a-dim_y)/2;
	
	
	w=window.open("","aa","location=no,menubar=no,status=no,toolbar=no,scrollbars=no,resizable=no,width="+dim_x+",height="+dim_y);
       w.focus();
       w.moveTo(wi,he) 
	   
	   
	   		 w.document.writeln("<head>"+
        "<title>Villa Ariston</title>"+
"<style type='text/css'>"+

"a {font-family:verdana,arial;font-size:10px;color:#505050;text-decoration:none}"+

"a:hover {font-family:verdana,arial;font-size:10px;color:#ffffff;text-decoration:none}"+

"</style>"+
        "</head>"+

"<body bgcolor='#fff6e5' marginwidth='0' marginheight='0' leftmargin='0' topmargin='0' >"+
"<table height='100%' align='center'>"+
"<tr>"+
       "<td valign='middle'><img src='http://www.villaariston.it/images/fotodb/big/"+foto+"' border='0'></td>"+
"</tr>"+
"</table>"+

"</body>");

w.document.close();       

}







	function cartoline(foto){
	
	var newwin;


var l = screen.width;
var a = screen.height;

	//function crea(variabile,dim_x,dim_y){
	
	dim_x=300;
	dim_y=500;
	
	
	var wi = (l-dim_x)/2;
	var he = (a-dim_y)/2;
	
	
	w=window.open("","aa","location=no,menubar=no,status=no,toolbar=no,scrollbars=no,resizable=no,width="+dim_x+",height="+dim_y);
       w.focus();
       w.moveTo(wi,he) 
	   
	   
	   		 w.document.writeln("<head>"+
        "<title>Villa Ariston</title>"+
"<style type='text/css'>"+

".testo {font-family:verdana,arial;font-size:10px;color:#021b72}"+



"a {font-family:verdana,arial;font-size:10px;color:#505050;text-decoration:none}"+

"a:hover {font-family:verdana,arial;font-size:10px;color:#000000;text-decoration:none}"+

".textinputshort { font-size: 11px; border-top:#CCCCCC solid thin; border-bottom:#CCCCCC solid thin; border-right:#CCCCCC solid thin; border-left:#CCCCCC solid thin; font-family: verdana, helvetica, sans-serif; color: #333333}	"+

".textarea { font-size: 11px; color: #333333; border-top:#CCCCCC solid thin; border-bottom:#CCCCCC solid thin; border-right:#CCCCCC solid thin; border-left:#CCCCCC solid thin; font-family: verdana, helvetica, sans-serif; }	"+

".buttons { font-size: 10px; color: #333333; background-color:#ffffff; border-top:#CCCCCC solid thin; border-bottom:#CCCCCC solid thin; border-right:#CCCCCC solid thin; border-left:#CCCCCC solid thin; font-family: verdana, helvetica, sans-serif; }	"+

"</style>"+
        "</head>"+

"\n<body bgcolor='#fff6e5' marginwidth='0' marginheight='0' leftmargin='0' topmargin='0' >"+

"\n<form action='http://www.villaariston.it/cgi-bin/cmail.pl' method=post >"+
"\n<input type=hidden name=dominio value='villaariston.it'>"+
"\n<input type=hidden name=subject value='cartolina dal sito www.villaariston.it'>"+
"\n<input type=hidden name=allegato value='/images/fotodb/normal/"+foto+"'>"+
"\n<input type=hidden name=paginautente value='http://www.villaariston.it/pag_ut.htm'>"+
"\n<input type=hidden name=paginacliente value='http://www.villaariston.it/pag_cli.htm'>"+



"<table align='center'>"+
"<tr>"+
       "<td valign='middle'><img src='http://www.villaariston.it/images/fotodb/normal/"+foto+"' border='0'></td>"+
"</tr>"+
"</table>"+
"<table>"+

"<table width='280' align='center'>"+
"<tr>"+
       "<td class='testo'>e-mail mittente:</td>"+
       "<td class='testo'><input name='email' type='text' class='textinputshort'></td>"+
"</tr>"+
"<tr>"+
       "<td class='testo'>e-mail destinatario:</td>"+
       "<td class='testo'><input name='mailto' type='text' class='textinputshort'></td>"+
"</tr>"+
"<tr>"+
       "<td class='testo' valign='top'>messaggio:</td>"+
       "<td class='testo'><textarea name='messaggio' rows=10 cols=20 class='textinputshort' ></textarea></td>"+
"</tr>"+

"<tr>"+
       "<td class='testo' valign='top'></td>"+
       "<td class='testo' align='right'><input type='submit' value='invia' class='buttons'>&nbsp;&nbsp;&nbsp;</td>"+
"</tr>"+

"</table>"+


"</form>"+
"</body>");

w.document.close();       

}





	function zoom_meet_ita(foto){
	
	var newwin;


var l = screen.width;
var a = screen.height;

	//function crea(variabile,dim_x,dim_y){
	
	dim_x=640;
	dim_y=530;
	
	
	var wi = (l-dim_x)/2;
	var he = (a-dim_y)/2;
	
	
	w=window.open("","aa","location=no,menubar=no,status=no,toolbar=no,scrollbars=no,resizable=no,width="+dim_x+",height="+dim_y);
       w.focus();
       w.moveTo(wi,he) 
	   
	   
	   		 w.document.writeln("<head>"+
        "<title>Villa Ariston</title>"+
"<style type='text/css'>"+

"a {font-family:verdana,arial;font-size:10px;color:#505050;text-decoration:none}"+

"a:hover {font-family:verdana,arial;font-size:10px;color:#000000;text-decoration:none}"+

"</style>"+
        "</head>"+

"<body bgcolor='#fff6e5' marginwidth='0' marginheight='0' leftmargin='0' topmargin='0' >"+
"<table height='100%' align='center'>"+
"<tr>"+
       "<td valign='middle'><img src='http://www.villaariston.it/images/fotodb/big/"+foto+"' border='0'></td>"+
"</tr>"+
"<tr>"+
       "<td valign='bottom' align='right'><a href='javascript:window.print()'>stampa</a>&nbsp;&nbsp;</td>"+
"</tr>"+
"</table>"+

"</body>");

w.document.close();       

}
