Opened 10 years ago
Closed 10 years ago
#12812 closed bug (notabug)
$().add(html) returns different result on IE compared to Firefox/Chrome
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | undecided | Milestone: | None |
Component: | unfiled | Version: | 1.8.2 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
$().add("<div><option> hello </option></div>").html()
IE (9): returns " hello "
Chrome/Firefox: returns "<option> hello </option>"
Change History (2)
comment:1 Changed 10 years ago by
comment:2 Changed 10 years ago by
Resolution: | → notabug |
---|---|
Status: | new → closed |
Agreed, invalid HTML has undefined results.
Note: See
TracTickets for help on using
tickets.
This is not valid HTML
OPTION is not allowed in DIV!
Try:
and everything works fine (though still crappy code, you don't have to use .add() here)