Opened 11 years ago
Closed 11 years ago
#10492 closed bug (invalid)
find(".class") behaves different in IE / Moz when element has more than one class
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | undecided | Milestone: | None |
Component: | unfiled | Version: | 1.6.4 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
<div id="parent">
<select class="classone classtwo">
<option value="1" selected>one</option> <option value="2">two</option>
</select>
</div>
<script type="text/javascipt">
alert ($("#parent").find(".classtwo").val()); works in Chrome but not in IE.
</script>
Change History (3)
comment:1 Changed 11 years ago by
comment:2 Changed 11 years ago by
Yep, sorry. I did the same with this code and it worked in IE. I must be having some other issue but jumped to this conclusion without checking properly.
find is all good...
comment:3 Changed 11 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
Note: See
TracTickets for help on using
tickets.
Could this be a problem with alert()? Or perhaps running your script before document ready?
I created a small test page (http://bobholt.me/10492.html) and got the expected result in IEs 9, 8, 7, and 6 as long as I wrote it to the page and didn't use alert().
This code on my test page seems to work: