[whatwg] [wf2] no value selected for type=range

Anne van Kesteren fora at annevankesteren.nl
Mon Aug 1 08:49:08 PDT 2005


Quoting Anne van Kesteren <fora at annevankesteren.nl>:
> Should it fall back to its initial value which is defined
> to be equivalent to the value of the MIN attribute or should something else
> happen?

Found this:

# For value attributes that are invalid according to the min, max, step,
# maxlength, etc, attributes
#    The control must be set to that value. The form will not submit with that
# value, though. If the control cannot be set to that value (for example, a
# range control cannot represent values outside its range) then the value must
# be clamped to the nearest value that can be represented by the 
control. (This
# situation can also arise if these attributes are dynamically updated using
# the DOM.)

So it should clip to the nearest value. Which is basically MAX or MIN 
depending
on which has overflow.


-- 
Anne van Kesteren
<http://annevankesteren.nl/>




More information about the whatwg mailing list