function setVal() {


dz=document.form.numberofdays.options[document.form.numberofdays.selectedIndex].value;

//window.alert(dz);

arrivalday=document.form.arrivalday.options[document.form.arrivalday.selectedIndex].value;
arrivalmonth=document.form.arrivalmonth.options[document.form.arrivalmonth.selectedIndex].value;
arrivalyear=document.form.arrivalyear.options[document.form.arrivalyear.selectedIndex].value;

lang=document.form.lang.value;

sstemp = new Date(arrivalyear,arrivalmonth-1,arrivalday);
ss = sstemp.getTime();

nodis=0; 
min34 = minimum(dz,ss)
if (min34 == false) 
{return false;}

onenite = one_nightt()
if (onenite == false) 
{return false;}

}


function one_nightt() {

sstemp = new Date(arrivalyear,arrivalmonth-1,arrivalday);
ss = sstemp.getTime();

dayuvweak = new Date (ss);
dayuvweak = dayuvweak.getDay()



//IF USING THE FRENCH WE HAVE NO LANG
if (lang == undefined)
{
lang="eng"
} 

if (lang == "eng")
{oneday_textt = "It is not possible to book only one night on a Friday or Saturday.";}

if (lang == "span")
{oneday_textt = "No se puede reservar una noche los viernes o sábados.";}





if ((dayuvweak > 4) && (dz == 1))
{
window.alert(oneday_textt)
nodis = false;
return false;
}
}

          

