Conversion of \n and other escapes for email piped to php
I'm trying to process emails piped to php. The resulting email (parsed into a variable) in php has a bunch of \n marks that do not seem to resolve back into new lines, etc., when php simply re-pipes it over with a mail()
. Ideally, it should be readable when re-piped from the 开发者_运维知识库other end - is there a way to simply convert all these \n's \r's and other escape's?
Did you use nl2br() ? It converts \n and \r\n to <br>
.
精彩评论