Possible Duplicate:
jQuery - Get selected element's outer HTML
so I have a div..
<div id="fred">
it has stuff in it
<div id="fred">
<tr id="thing1">hello1</tr>
<tr id="thing2">hello2</tr>
</div>
if I call
$("#fred").html();
I get just the items inside:
<tr id="thing1">hello1</tr>
<tr id="thing2">hello2</tr>
I want the whole thing:
<div id="fred">
<tr id="thing1">hello1</tr>
<tr id="thing2">hello2</tr>
</div>
I know that I can ref using this[0], but it seems like there should be an easier way..
I tried .andSelf()
but apparently that doesn't do what I thought it should doo..