Replace a tag with another in jQuery Replace the anchor tag inside div class=”normal replace” with normal div tag while keeping it’s content.
$('.normal > a').replaceWith(function() {
return $('<div/>', {
html: this.innerHTML
});
});