Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Useful Jquery Examples.
$('#id').replaceWith('<div>I have been replaced</div>');
I prefer
$('#id').replaceWith($('<div/>').text('I have been replaced.'));
There are no comments on this comment yet.
$('#id').replaceWith('<div>I have been replaced</div>');
I prefer
$('#id').replaceWith($('<div/>').text('I have been replaced.'));