I'm encountering an issue with my registration page where it functions properly in Firefox, but IE 6-8 displays a 'document.info.altDate1.value' error upon submission.
Here is the structure of the body:
<DIV id=wrapper>
<DIV id=outer-space>
<DIV id=hfeed>
<H1>Register for <SPAN>Orientation</SPAN></H1>
...
The problem seems to be linked to these specific fields:
<SELECT id=freshmandate name="">
and
<SELECT id=transferdate name="">
as well as this function:
if (document.info.StudentType.value == 'F')
{
document.info.freshmandate.name = 'altDate1';
document.info.amount.value = '105.00';
}
if (document.info.StudentType.value == 'T')
{
document.info.transferdate.name = 'altDate1';
document.info.amount.value = '75.00';
}
A friend suggested using GetElementByID for better compatibility in IE, but I'm unsure how to implement it effectively for my requirements.
Edit 1: I attempted the following approach which didn't work and now even Firefox has issues:
if (document.info.StudentType.value == 'F')
{
document.getElementById('freshmandate').name = 'altDate1';
else
document.getElementById('transferdate').name = 'altDate1';
}