Re: [selectors4] hash reference, reverse reference, and multi-reference combinators

Le 06/07/2013 08:21, Tab Atkins Jr. a écrit :
> On Wed, Jul 3, 2013 at 9:24 PM, Boris Zbarsky <> wrote:
>> On 7/3/13 8:19 PM, Tab Atkins Jr. wrote:
>>> Yes, it does.  The spec defines that the attribute has to contain
>>> either an IDREF or an id selector, and an in-page link qualifies as
>>> the latter (so long as it's just the hash).
>> Er... the syntax for an in-page #foo link and a #foo selector are different
>> as soon as you try to use most non-alphanumerics (or anything non-ASCII that
>> you do via escapes).
> Sure, but so long as you're not doing that, it's fine.
> (Also, oh look, a good reason to just adopt the quirks-mode behavior
> and not nanny anyone.)

Do you mean the <hash> vs. '#'<ident> quirk? It’s not just that: ASCII 
has plenty of punctuation that’s allowed in URL fragments but not ID 
selectors, and character escaping is completely different ('%'<byte> vs. 

I agree with Boris that you can not just pretend that they are the same. 
Instead you’d probably want a definition that involves URL parsing, like 

Simon Sapin

Received on Saturday, 6 July 2013 08:02:38 UTC