I know this is simple, but I can't get it working. I'm hoping someone here can help.
First off, this is part of a web app for iOS.
Okay, I have a list of items:
Room Type: <select id="isoList" name="isoList">
<option></option>
<option value="20">ISO 8 Life Sciences Low Use</option>
<option value="25">ISO 8 Life Sciences Med Use</option>
<option value="30">ISO 8 Life Sciences High Use</option>
</select>
I need to have the user select the room type, then pass the option value - as a var - to another function that uses the var in a calculation.
Here's the script I have to far. My form is named airflow...
function isoChange()
{
var isoChange = document.airflow("isoList");
var airChanges = isoChange.options[isoList.selectedIndex].value;
}
Now I want to pass airChanges to this function...
function calcAF(airChanges)
{
var length = document.airflow.length.value; //length
var width = document.airflow.width.value; //width
var height = document.airflow.height.value; //height
var changes = airChanges; // hourly air changes
}
From there the calcAF function will use the var in various math formulae.
I've got it to work if I get the user to tell me airChanges, but it breaks when I try to get the airChanges from a drop down list.