Modify ↓
Ticket #6628 (closed bug: invalid)
change HTML to div inside a tag
| Reported by: | mikis | Owned by: | |
|---|---|---|---|
| Priority: | Milestone: | 1.4.3 | |
| Component: | manipulation | Version: | 1.4.2 |
| Keywords: | html div a | Cc: | |
| Blocking: | Blocked by: |
Description
When attempting to modify the html of a div which inside of an A tag you get a result of extra a tag inside the div.
The bug is only occur in FF (I'm using 3.6)
Here's the example of my code:
<script type="text/javascript" language="javascript">
$(document).ready(function(){
$("#a_tag").html("OK"); $("#div_tag").html("OK"); $("#divanda_tag div").html("Problem");
});
</script> <a id="a_tag"></a> <div id="div_tag"></div> <a id="divanda_tag"><div></div></a>
Change History
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.
Note: See
TracTickets for help on using
tickets.

The markup is invalid. An <a> tag is an inline element but a <div> is a block element.