Side navigation
#1960 closed enhancement (wontfix)
Opened November 22, 2007 07:43PM UTC
Closed May 06, 2008 12:13AM UTC
Last modified March 15, 2012 12:44AM UTC
Name selectors should delegate to document.getElementsByName
Reported by: | sil | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 1.2.4 |
Component: | core | Version: | 1.2.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
The selector $("*[@name=foo]") should delegate to document.getElementsByName("foo"), since getElementsByName is natively implemented and therefore faster. (This assumes that you can recognise this selector type fast enough that it's worth checking for it to do the delegation, of course.)
Attachments (2)
Change History (7)
Changed April 22, 2008 09:33PM UTC by comment:1
Changed April 22, 2008 10:47PM UTC by comment:2
Both patches break "selector module: attributes" test 19. and 20., related to :not()
Changed April 22, 2008 11:59PM UTC by comment:3
I made a few attempts but it just fails when doing :not. I restricted it to only positive filters, see if this passes, I g2g, I'll try to test this myself :)
Changed April 28, 2008 02:16PM UTC by comment:4
resolution: | → fixed |
---|---|
status: | new → closed |
Fixed in [5343].
Changed May 05, 2008 06:01AM UTC by comment:5
resolution: | fixed |
---|---|
status: | closed → reopened |
document.getElementsByName can only retrieve elements in the document tree. see #2787
Changed May 06, 2008 12:13AM UTC by comment:6
resolution: | → wontfix |
---|---|
status: | reopened → closed |
Right, reverted at [5460], good catch.
Changed May 13, 2008 05:40PM UTC by comment:7
milestone: | 1.2.2 → 1.2.4 |
---|
I did a quick benchmark, the page had 533 elements, 7 of them matched the name.
The call was
Results: