Thread: formated mail
View Single Post
Old 03-26-2008, 12:00 AM   #3 (permalink)
baruch menachem
Junior Member
 
Join Date: Mar 2008
Location: Sullivan's Gulch
Posts: 3
Send a message via MSN to baruch menachem Send a message via Skype™ to baruch menachem
Default Re: formated mail

I found a really good way of solving this on another board. The only thing is, I think I am using the wrong char.


the code looks like this:

Quote:
$message=$_POST["message"];
$newMessage=str_replace(Chr(13),'</p><p>',$message);
$newMessage='<p>'.$newMessage;
$message= $newMessage;
the problem with this is, it takes all the line breaks from the text area and makes them new lines. I want to put in a new line when the author of the message makes a new line. So I think 13 is the wrong number. Especially when I look at the source of my web page after it is done, and the source is formated correctly, but the text on the HTML page is not.
baruch menachem is offline   Reply With Quote
Sponsored Links