function showmenu(id) {


if (document.getElementById(id).style.display=="inline") {

  document.getElementById(id).style.display="none";
  
 //setTimeout(function(){document.getElementById(id).style.display="none"}, 100);

} else {

document.getElementById(id).style.display="inline";
//document.getElementById(id).style.firstLetter="font-size: xx-large;";
  }

} 


function chk_sform() {

 if (document.studentform.txtfirstname.value =="") {

 alert("Var vänlig fyll i ditt förnamn");
   document.studentform.txtfirstname.focus();
   document.getElementById('txtfirstname').style.border="1px solid red";
   return(false);

 }

if (document.studentform.txtlastname.value =="") {

 alert("Var vänlig fyll i ditt efternamn");
   document.studentform.txtlastname.focus();
document.getElementById('txtlastname').style.border="1px solid red";
   return(false);

 }

if (document.studentform.txtaddress.value =="") {

 alert("Var vänlig fyll i din adress");
   document.studentform.txtaddress.focus();
document.getElementById('txtaddress').style.border="1px solid red";
   return(false);

 }

if (document.studentform.txtzipcode.value =="") {

 alert("Var vänlig fyll i ditt postnummer");
   document.studentform.txtzipcode.focus();
document.getElementById('txtzipcode').style.border="1px solid red";
   return(false);

 }

if (document.studentform.txtcity.value =="") {

 alert("Var vänlig fyll i ort");
   document.studentform.txtcity.focus();
document.getElementById('txtcity').style.border="1px solid red";
   return(false);

 }

if (document.studentform.txtemail0.value =="") {

 alert("Var vänlig fyll i Epostadress");
   document.studentform.txtemail0.focus();
document.getElementById('txtemail0').style.border="1px solid red";
   return(false);

 }

if (document.studentform.txtpnum.value =="") {

 alert("Var vänlig fyll i personnummer");
   document.studentform.txtpnum.focus();
   document.getElementById('txtpnum').style.border="1px solid red";
   return(false);

 }

if (document.studentform.terminsvis0.checked && document.studentform.aretrunt.checked) {


alert("Du kan välja hyra antingen läsårsvis ELLER åretrunt");
return false;

}


else {
return(true);
}

}



function chk_vform() {


if (document.vardform.namn.value =="") {

 alert("Var vänlig fyll i ditt namn");
   document.vardform.namn.focus();
   document.getElementById('namn').style.border="1px solid red";
   return(false);

 }

if (document.vardform.teldag.value =="" && document.vardform.epost.value =="" && document.vardform.mobil.value=="" && document.vardform.telkvall.value =="") {

 alert("Var vänlig fyll i telefonnummer, eller E-postadress eller mobilnummer");
   document.vardform.teldag.focus();
   document.getElementById('teldag').style.border="1px solid green";
   document.getElementById('telkvall').style.border="1px solid green";
   document.getElementById('mobil').style.border="1px solid green";
   document.getElementById('epost').style.border="1px solid green"; 
   return(false);

 }

if (document.vardform.beskrivning.value =="") {

 alert("Var vänlig fyll i beskrivning");
   document.vardform.beskrivning.focus();
   document.getElementById('beskrivning').style.border="1px solid red";
   return(false);

 }



else {
return(true);
}

}

