[whatwg] 9.2.1.2.3 spaces between quoted attribute values

On Fri, 1 Dec 2006, Elliotte Harold wrote:
>
> Attributes names and unquoted attribute values must be separated from 
> each other and from the tag name and the U+002F SOLIDUS character 
> mentioned below (if present) by one or more space characters.
> 
> Is this then legal?
> 
> <p id="p1"class="foo">

Yes.


> Shouldn't quoted attribute values also be separated by space from 
> attribute names?

No, it isn't necessary. Browsers support this interoperably, and it was 
allowed in HTML4, so there are almost certainly documents depending on it. 
You're allowed to put spaces there, but not required to.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

Received on Friday, 1 December 2006 08:58:58 UTC