On Fri, Jun 12, 2009 at 2:37 PM, amuhlou<amysch...@gmail.com> wrote: > > putting it all together, you'd get something like: > > $('#div1').replaceWith($('#div2')).remove(); > > first you find div1, then replace it with div2, then remove div1
There's no need for remove() because it will have been replaced already.