I want to insert an image tag into a body of content after 3 <br><br>'s occur
eg I have a variable called $content which has about 6 paragraphs and the paragraph separator is <br><br>.
here is the code im using
if($master_img3){
$content2=explode("<br><br>",$content);
$content3="";
for($i=1; $i<=3; $i++){
$content3.="<br><br>$content2[$i]";
}
$image_code="<img src=\"/images/articles/$master_img3\" align=\"left\">";
$content4=$content3;
$content4.=$image_code;
if($debug==1){echo"image_code:$image_code";}
preg_replace("$content3","$content4","$content");
}
im getting an error for the preg_replace line (Unknown modifier '<' in line XX)
don't know what I'm doing wrong, i thought i was following the manual to the letter.......