<?php $source = '<img src="source.jpg">'; $string = '<div id="pf1" class="pf w0 h0" data-page-no="1"> <div class="pc pc1 w0 h0"> <img class="bi x0 y0 w0 h0" alt="" src="../images/cover.jpg"/> </div>'; $find = '/<img(.*?)\/>/'; echo preg_replace($find, $source, $string);
You have javascript disabled. You will not be able to edit any code.