xlegend
07-31-2003, 08:28 PM
I'm trying to help a friend with this code... can anyone give me an answer to his problem
Okay......I'm at my wits end. If there are any JavaScript guru's out there let me know. The code below doesnt work right in IE 6, but works grewat in IE 5. Anyone see anything?
var questiontext = form.AssessmentQuestions.options[form.AssessmentQuestions.selectedIndex].text;
var questionlength = questiontext.length;
var MaturityLevelQuestion = form.AssessmentQuestions.options[form.AssessmentQuestions.selectedIndex].text.substring(questionlength-2,questionlength-1);
for (var i = 0; i < form.MaturityLevel.length; i++){
if (form.MaturityLevel.options.selected){
var MaturityLevelAnswer = form.MaturityLevel.options.value;
}
}
if (MaturityLevelAnswer > MaturityLevelQuestion){
error = 1;
results = results + "\n" + "Maturity Level can be no high than " + MaturityLevelQuestion + "!";
}
}
}
How is this fixed?
Okay......I'm at my wits end. If there are any JavaScript guru's out there let me know. The code below doesnt work right in IE 6, but works grewat in IE 5. Anyone see anything?
var questiontext = form.AssessmentQuestions.options[form.AssessmentQuestions.selectedIndex].text;
var questionlength = questiontext.length;
var MaturityLevelQuestion = form.AssessmentQuestions.options[form.AssessmentQuestions.selectedIndex].text.substring(questionlength-2,questionlength-1);
for (var i = 0; i < form.MaturityLevel.length; i++){
if (form.MaturityLevel.options.selected){
var MaturityLevelAnswer = form.MaturityLevel.options.value;
}
}
if (MaturityLevelAnswer > MaturityLevelQuestion){
error = 1;
results = results + "\n" + "Maturity Level can be no high than " + MaturityLevelQuestion + "!";
}
}
}
How is this fixed?