function checkCush( ) {
var errorlength = 0
var dimtype = document.form1.measure.value ;
if (dimtype=="Inches")
{ errorlength = 3 }
else
{ errorlength = 7.5 }

if (document.form1.length.value.length <1 ) 
{alert ("Please put a value in the length box") 
       return false}
if (document.form1.width.value.length <1 ) 
{alert ("Please put a value in the width box") 
       return false}  
if (document.form1.depth.value.length <1 ) 
{alert ("Please put a value in the depth box") 
       return false} 
if (document.form1.depth.value <errorlength ) 
{alert ("Please note that unfortunately we are unable bullnose cushions less than 3 inches (7.5cm) in depth") 
       return false}
document.form1.submit()
return true
}


function boxChangecush(x){
if (x==3) {
document.form1.firmness.selectedIndex=1 ;
document.form1.firmness.disabled=true
}
else {
document.form1.firmness.disabled=false
}
}


function boxChangewrap(x){
if (x>0) {
document.form1.stocking.selectedIndex=1 ;
document.form1.stocking.disabled=true
}
else {
document.form1.stocking.disabled=false ;
document.form1.stocking.selectedIndex=0
}
}
