NYCPHP Meetup

NYPHP.org

[nycphp-talk] Line break string evaulation help

Andrew Yochum andrew at plexpod.com
Fri Jan 13 16:10:01 EST 2006


On Fri, Jan 13, 2006 at 04:10:50PM -0500, cliff wrote:
> define('NEWLINE', "\n");
> 
> define ("EMAILFOOTER", NEWLINE.
> 'blah, blah, blah.'.NEWLINE.
> 'blah, blah, blah.'.NEWLINE.
> 'To login, click on the following link: '.URL);
> 
> This works fine when viewing an email generated by this code in a browser-
> based email client, but fails to break lines in Microsoft Outlook on XP. 
> What am I doing wrong?

Try "\r\n", which is a carriage return + line feed (\x0D\xOA)- the
windows/dos style. See:
    http://en.wikipedia.org/wiki/CRLF

HTH,
Andrew
-- 
Andrew Yochum
Plexpod
andrew at plexpod.com
718-360-0879



More information about the talk mailing list