I want to find all images inside some div and replace the image tag with some other code. Replace this:
<div id='sd'>
<img src="/images/panorami/53.jpg">
<img src="/images/panorami/other.jpg">
</div>
with:
<div id='sd'>
<a title="" rel="lightbox[images]" href="/images/panorami/53x.jpg">
<img src="/images/panorami/53.jpg"></a>
<a title="" rel="lightbox[images]" href="/images/panorami/otherx.jpg"><img src="/images/panorami/other.jpg"></a>
</div>
how this can be done with jQuery?
Demo.