W3C home > Mailing lists > Public > public-html@w3.org > February 2009

Re: fragid navigation and pct-encoded

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Wed, 18 Feb 2009 11:29:05 -0500
Message-ID: <499C3751.2030707@mit.edu>
To: Julian Reschke <julian.reschke@gmx.de>
CC: HTML WG <public-html@w3.org>
Julian Reschke wrote:
> So @id and @name are handled differently? Why?

The special name handling is only needed for names that are %-encoded. 
Names are, by and large, only %-encoded because of IE's matching 
behavior and because fragment IDs in URIs come %-encoded.

There are no %-encoded IDs around, typically.  Probably because there is 
not much use of them for fragment identifier matching.

The other reason, of course, is that the name handling _does_ cost extra 
parsing performance and changes the name attribute visible in the DOM. 
That was viewed as acceptable for IE compat on the issue of anchor 
matching, but making the same change to IDs would possibly affect 
getElementById (if the ID contains '%').  That was not viewed as desirable.

In short, "because the name handling is a hack we felt we needed for IE 

Received on Wednesday, 18 February 2009 16:29:50 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 29 October 2015 10:15:42 UTC