Here's how I ended up doing it (for any future viewers of the thread):
Actionscript code:
Import the right class:
import flash.external.ExternalInterface;
Create the function to call the JS function
private function getFormValues():void
{
firstName = ExternalInterface.call("getJSVar", "firstName");
lastName = ExternalInterface.call("getJSVar", "lastName");
address = ExternalInterface.call("getJSVar", "address");
phone = ExternalInterface.call("getJSVar", "phone");
email = ExternalInterface.call("getJSVar", "email");
}
(My variables [firstName, lastname, address, phone, and email] are defined as bindable strings)
Create the javascript function to get the latest values, and return them:
<script type="text/javascript">
function getJSVar(varName)
{
var toReturn = "Nothing Sent";
if (varName == "firstName")
toReturn = document.forms["userInfo"].firstName.value;
else if (varName == "lastName")
toReturn = document.forms["userInfo"].lastName.value;
else if (varName == "address")
toReturn = document.forms["userInfo"].address.value;
else if (varName == "phone")
toReturn = document.forms["userInfo"].phone.value;
else if (varName == "email")
toReturn = document.forms["userInfo"].email.value;
return toReturn;
}
</script>
Here's my html form too:
<form action='#' method='post' name="userInfo">
<table width='100%'>
<tr>
<td align='center'><input type='text' id="firstName" name="firstName" value='First Name' style='width:250px;' /></td>
<td align='center'><input type='text' id="ymm" name='ymm' value='Year Make Model' style='width:250px;' /></td>
</tr>
<tr>
<td align='center'><input type='text' id="lastName" name='lastName' value='Last Name' style='width:250px;' /></td>
<td align='center'><input type='text' id="address" name='address' value='Address' style='width:250px;' /></td>
</tr>
<tr>
<td align='center'><input type='text' id="phone" name='phone' value='Phone Number' style='width:250px;' /></td>
<td align='center'><input type='text' id="email" name='email' value='Email Address' style='width:250px;' /></td>
</tr>
</table>
</form>