PHP Email Form
| From: | Declan Kenny | Date: | Tue, 09 Apr 2002 11:01:28 +0000 |
| Subject: | PHP Email Form | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-92207@lists.php.net to get a copy of this message | ||
Hi I have an online email form but I can't get the text layout the same as
the layout someone types in the text Area, here is the final bit of code:
$message = stripslashes($message);
$message = htmlentities($message);
$message = nl2br($message);
$from="From: $email";
$to= "myaddress@domain.com";
mail($to,$subject,$message,$from);
Basicly the problem is if someone puts a new line in the text area this
appears as <BR />. example:
Hi,
this is a test
would end up
Hi,
<br />
this is a test.
Any help please?