<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
<META NAME="GENERATOR" CONTENT="GtkHTML/3.26.3">
</HEAD>
<BODY>
On Fri, 2010-06-18 at 13:03 -0400, Eitan Adler wrote:<BR>
<BLOCKQUOTE TYPE=CITE>
<BR>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
On Fri, Jun 18, 2010 at 12:58 PM, Gordon P. Hemsley <<A HREF="mailto:gphemsley@gmail.com">gphemsley@gmail.com</A>> wrote:<BR>
<BLOCKQUOTE>
I'm not sure how you interpreted, but I wanted to clarify, in case it wasn't clear.<BR>
<BR>
I'm pretty sure this person is asking why @required isn't allowed on <select> elements.<BR>
<BR>
As in: <A HREF="http://dev.w3.org/html5/markup/forms-attributes.html#shared-form.attrs.required">http://dev.w3.org/html5/markup/forms-attributes.html#shared-form.attrs.required</A>
</BLOCKQUOTE>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
<BLOCKQUOTE>
<BR>
I don't know what the exact reasoning is for it not being on there, nor do I know exactly how @required is supposed to be enforced, but I do think that the method suggested in the bug is a bad one. Sometimes, authors will include an empty <option> on purpose in order to allow for an empty option to be selected.
</BLOCKQUOTE>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
<BR>
Perhaps the @requires attribute could be handled somewhat differently. If present the "default" value becomes the "not allowed" value and the browser would require you to change the value before submitting the form.<BR>
<BR>
<BR>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
-- <BR>
Eitan Adler<BR>
</BLOCKQUOTE>
<BR>
I would think it makes more sense for the app/site to choose a sensible default value. For instance, instead of the daft "-- please select a month--" type of options, how about just picking January by default and then letting the user override it? It's what I do on all my apps, and makes sense to me that if the user isn't bothered about changing the value, I only need care about whether it's a sensible value, and not whether it was actually a conscious choice.<BR>
<BR>
<TABLE CELLSPACING="0" CELLPADDING="0" WIDTH="100%">
<TR>
<TD>
Thanks,<BR>
Ash<BR>
<A HREF="http://www.ashleysheridan.co.uk">http://www.ashleysheridan.co.uk</A><BR>
<BR>
<BR>
</TD>
</TR>
</TABLE>
</BODY>
</HTML>