The "required" option for CFSELECT is rather silly, when you consider
how SELECT boxes work. In a SELECT, something is always selected (the
default option, if not changed).
That's why you've gotta write your own code:
(assuming that you want something other than the first option selected)
<select name="selectBox" onChange="if (! this.selectedIndex){alert('You
must select an option.')}">
You can use this in a CFSELECT as well.
Scott Weikert wrote:
>
> Hey gang...
>
> Trying to set up several <CFSELECTS> in a form, making each of them
> requiring a choice.
> I'm manually creating a query for each one, and referencing it in the
> CFSELECT tag.
> Now, the first item in the query is what will get passed, as its the first
> item in the select - so
> how do you tell it to make a choice required? Looking at the resulting
> source for the page, none
> of the items default to reading "selected"...
>
> --Scott
>
>
>------------------------------------------------------------------------------------------------
> Archives: http://www.mail-archive.com/[email protected]/
> Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send a message
>with 'unsubscribe' in the body to [EMAIL PROTECTED]
------------------------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send a message
with 'unsubscribe' in the body to [EMAIL PROTECTED]