Ticket #4081 (closed bug: fixed)
Simple name selector not working in 1.3.1 with IE 6
| Reported by: | luqi | Owned by: | john |
|---|---|---|---|
| Priority: | major | Milestone: | 1.3.2 |
| Component: | selector | Version: | 1.3.1 |
| Keywords: | Cc: | ||
| Blocking: | Blocked by: |
Description
It works fine in 1.2.6 but not working in 1.3.1.
Attachments
Change History
comment:1 Changed 4 years ago by Rwhitbeck
Interesting. In IE6 and IE8RC the selector he is using doesn't work in 1.3 or 1.3.1 but works fine in 1.2.6
If you add a td to the selector I can get the text() method to return the text. ( $("tr[name='pv'] td").text(); -> content before)
If you put a name on the td and try to select it with the name attribute it still won't work ($("td[name='pv1']").text(); -> blank)
If you try a different attribute other then name it works fine. change <tr name="pv"> to <tr valign="top"> and use the selector ( $("tr[valign='top']").text(); -> content before ) works as expected.
Tested in both IE6 and IE8RC don't have access to IE7.
Hope this helps in troubleshooting the bug.
comment:2 Changed 4 years ago by Rwhitbeck
Additional info: tested against Firefox 3 worked as expected. Tested against Safari worked as expected.
Tested in IE against the nightly built and it failed as stated above.
comment:3 Changed 4 years ago by Rwhitbeck
One last thought. the TR tag does not have a "name" attribute listed as a optional or standard attribute. This maybe why it doesn't work correctly in IE.
comment:4 Changed 4 years ago by seasoup
I reproduced this bug in ie7 as well
<table> <tbody name="testname"> <tr>
<td>test</td>
</tr> </tbody> </table>
<script>alert($('[name=testname]').size());</script>
alerts 1 in firefox 3.06, chrome, opera 9.62, webkit, safari 3.2.1, and 0 in ie7, ie6
comment:5 Changed 4 years ago by seasoup
@Rwhitbeck tested it in the table tag as well, same results.
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

