[whatwg] input type="url" allow URLs without http:// prefix
Kornel
kornel at geekhood.net
Mon Jul 13 03:52:15 PDT 2009
On 13 Jul 2009, at 08:52, Bruce Lawson wrote:
> I'd like to suggest that input
>>> type="url" allows the http:// prefix to be optional on input and,
>>> if ommitted, be assumed when parsing.
>>
>> The spec explicitly allows that actual value seen and edited by the
>> user in the interface is different from DOM value of the input, so
>> browsers are free to prepend http:// automatically (and IMHO should
>> – DSK-253195).
>
> Excellent. And, while I don't doubt you at all, I'm abashed that I
> missed that nuance, especially as it'#s explicitly allowed? Where
> would I find that in the spec?
The "URL state" section says that value in DOM may be different from
value in the user interface:
http://www.whatwg.org/specs/web-apps/current-work/multipage/forms.html#url-state
The example difference given in the spec is URL-escaping, but in my
understanding, it should allow to prepending of protocol as well (I
admit that last bit is not stated explicitly).
--
regards, Kornel
More information about the whatwg
mailing list