Hey all,
So I started using nl2br and love it. But when I convert back from
<br> to \n, it produces double spaces instead of single space.
Converting \n to <br>:
$emailBody=nl2b r($_POST["emailBody"]);
$emailBody=str_ replace("<br />", "<br>", "$emailBody ");
Converting <br> to \n:
$edit["emailBody"]=str_replace("< br>","\n",$edi t["emailBody"]);
Now what was once single new lines is now doubled.
Any ideas?
--Matt
So I started using nl2br and love it. But when I convert back from
<br> to \n, it produces double spaces instead of single space.
Converting \n to <br>:
$emailBody=nl2b r($_POST["emailBody"]);
$emailBody=str_ replace("<br />", "<br>", "$emailBody ");
Converting <br> to \n:
$edit["emailBody"]=str_replace("< br>","\n",$edi t["emailBody"]);
Now what was once single new lines is now doubled.
Any ideas?
--Matt
Comment