I created divs using:
$('.images').find('img').replaceWith(function () {
return '<div class="resize">' + this.outerHTML + '</div>'
});
Output HTML:
<div class="images">
<div class="resize"><img src="img1.jpg"></div>
<div class="resize"><img src="img2.jpg"></div>
<div class="resize"><img src="img3.jpg"></div>
</div>
Now I would like to revert to this, is it possible?
<div class="images">
<img src="img1.jpg">
<img src="img2.jpg">
<img src="img3.jpg">
</div>