I want to get the html including the selector that I am using to get the html
let's say I have
<div id="foo">
<div id="bar">content</div>
</div>
when I do $('#foo').html()
I get
<div id="bar">content</div>
Is there a way in jquery to get the whole html including the parent(selector div)
I want this whole html
<div id="foo">
<div id="bar">content</div>
</div>