Hi, I am using a php script that sends mail using \n in the body to start new lines.
When I open the mail in outlook its written all in one line though.
Does anyone know how this can be fixed or why it’s happening?
Thanks!
Hi, I am using a php script that sends mail using \n in the body to start new lines.
When I open the mail in outlook its written all in one line though.
Does anyone know how this can be fixed or why it’s happening?
Thanks!
There are a few possible fixes listed at:
PHP: mail - Manual
or you can use better(more features and no LF issue) mailer classes like swiftmailer or phpmailer.
They both come with easy examples.
Do a search and replace to put \r\n in place of all the \n. Or, use phpmailer like tanmaya suggests.
Tim