getElementsByTagName('*')['...'] doesn't work as expected when used to search for child elements where multiple parent elements have sub-elements of the same id. Even though the element sought is in the "collection", it isn't returned when trying to access the element by name. It works when for the first parent element, but not for subsequent parent elements. I'll attach a test case.
Only tested in Safari 3.0.3 (522.15.5) on Windows XP.
Created attachment 16209 [details]
Forgot to mention: works in Firefox, Opera, IE7.
Confirmed with a local debug build of WebKit r25386 with Safari 3 Public Beta v. 3.0.3 (522.12.1) on Mac OS X 10.4.10 (8R218).
Not a regression as the same issue occurs with Safari 2.0.4 (419.3) with original WebKit on 10.4.10.
FWIW, I get the same results using childNodes -- though accessing that NodeList by id doesn't seem well supported cross-browser. Heck, now I've found that NodeList doesn't have any standard method for access by id, but it would be nice if worked consistently where it does work. :)
This works in Safari 5. Not sure when this was fixed, might make sense to land a regression test.
Yes, seems to be fixed in both Safari 5 and Chrome 7 on Windows.