|
SELECT tags can be validated in two ways - by selectedIndex, or by the value of the selectedIndex. (Notice the capital "I".. it must be capitalized, or it won't work.)
If your form name is "formName" and the select is named "selectName":
if(document.forms["formName"].selectName.selectedIndex == 0) means "if the select is in the first position" (it's a zero-based index.)
if(document.forms["formName"].options[document.forms["formName"].selectedIndex].value == "") means "if the value of the current selection is blank".
__________________
^_^
If anyone knows of a website that can offer ColdFusion help that isn't controlled by neurotic, pedantic jerks* (stackoverflow.com), please PM me with a link.
* The neurotic, pedantic jerks are not the owners; just the people who are in control of the "popularity contest".
|