
function EmailInfo(label,stile) {
  var name='info';
  var domain='sevim.it';
  var email=name + '@' + domain;
  if (!label || label=='') var label=email;
  if (!stile || stile=='') var stile='style=\"font-family: Tahoma; color: #FFFFFF; font-size: 10 px\"';
  document.write('<a href=\"mailto:' + email + '\" '+stile+'>');
  document.write(label + '</a>');
}

function em(tipo,nome)
{ 
  var dominio='sevim.it';
  if (!tipo) var tipo='u';
  if (!nome) var nome='info';
  if (tipo.toLowerCase()=='u'){
     document.location='mailto:'+nome+'@'+dominio;
    }
  else {
     document.write(nome+'@'+dominio);
    }   
}


function nuovafin(strUrl,larghezza,altezza,barre){
  if (!larghezza) {
     larghezza=660;
     altezza=450;
     barre=1;
  }

  if (screen.width<larghezza){larghezza=screen.width}

  winFin=window.open(strUrl,
  "nuovafin",
  "resizable=no,toolbar=no,directories=no,menubar=no,scrollbars="+barre+",width="+larghezza+",height="+altezza+",left=10,top=10");
  winFin.focus();
  
  return false;
};


function ModuloInfo(theForm)
{

var i=0;
var linea="================================================================\n";
var linea2="----------------------------- ";
var temp="";
var campi=theForm.elements;
var exp=new Date();
var data_invio=exp.getDate()+"/"+(exp.getMonth()+1)+"/"+exp.getYear()+" "+exp.getHours()+":"+exp.getMinutes()+":"+exp.getSeconds();
// var data_invio=exp.toLocaleString().toUpperCase(); //.toGMTString().split(',')[1].split('UTC')[0];
var oggetto=campi["oggetto"].value;
var d="";
var nome="";
var nomeup="";
var valore="";
var tipo;

d="Modulo del "+data_invio+"\n";
d+=linea;
d+=" "+oggetto.toUpperCase()+"\n";
d+=linea;

// d+="\n"+linea2+"Dati Richiesta\n";

for (i=0;i<campi.length;i++) {
   nome=campi[i].name;
   nomeup=nome.toUpperCase()
   valore=campi[i].value;
   tipo=campi[i].type;

   if (nomeup!="MODULO"){
     // if (nome=="appalti") d+="\n"+linea2+"Parametri\n";
     if (nomeup=="INFOCAMERALI" || nomeup=="PRIVACY") d+="\n";
   
     if (tipo=="checkbox") if (campi[i].checked) d+=nome.toUpperCase()+": on\n";
     if (tipo.indexOf("select")>-1) d+=nome+": "+campi[i][campi[i].selectedIndex].value;
     if (tipo=="text" || tipo=="textarea") d+=nome+": "+valore.toUpperCase()+"\n";

     if (nomeup=="CONTATTO" || nomeup=="PARAMETRI") d+="\n";
   }   
 
}


d+=linea;

// alert(d);

return d;

}
