bmi calculator

if (!isNum(weight,"weight","weighterror")) return false; else if ( (weight 600) ) { setError("weighterror","Enter a valid weight"); focusit("weight"); return false; } else { setSuccess("weighterror"); }

if (oForm.weighttype[0].checked) { weightPounds = weight; weightKgs = weight / 2.2; } else { weightPounds = weight * 2.2; weightKgs = weight; }

if (oForm.height[0].checked) { //Imperial if (!isNum(feet,"feet","feeterror")) return false; else if ( (feet 7) ) { setError("feeterror","Between 4 and 7 feet"); focusit("feet"); return false; } else { setSuccess("feeterror"); }

if (!isNum(inches,"inches","incheserror")) return false; else if (inches > 11) { setError("incheserror","Less than 12"); focusit("inches"); return false; } else { setSuccess("incheserror"); }

height = ((feet*12) + inches) * 2.54; } else { if (!isNum(cm,"cm","cmerror")) { return false; } else if (cm " + displaybmi + "

";

myDiv = get("diva"); myDiv.innerHTML = s;

statusDiv = get("divb"); if (displaybmi =19 && displaybmi =26 && displaybmi =30 && displaybmi 40) statusDiv.innerHTML = "Extremely Obese" ;

//Scroll dataTarget = document.getElementById('Button1'); smoothScroll (dataTarget,500); return false; }

BMI CALCULATOR


Enter a valid weight