My form submits the value of textarea, then takes the value and emails it in a plaintext email. Problem is the no matter what I do, I cannot get the line breaks in the email.
Expand|Select|Wrap|Line Numbers
- $msg_text = $_GET['msg_text'];
- $email = "me@gmail.com";
- $subject = "My Subject";
- $headers = 'From: me@me.com' . "\r\n" .
- 'Reply-To: me@me.com' . "\r\n" .
- 'X-Mailer: PHP/' . phpversion();
- mail($email,$subject,$msg_text,$headers);
- echo "done";
Expand|Select|Wrap|Line Numbers
- <form action="FILE_NAME" method="GET">
- <textarea name="msg_txt" cols="50" rows="50"></textarea>
- <input type="submit" value="go">
- </form>
Any help would be greatly appreciated!