This is a discussion on How to fix mail() double line spacing in message body? within the PHP General forums, part of the PHP Programming Forums category; So, I don't quite get how to solve this. See code example below, which shows "normal" CR/...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
So, I don't quite get how to solve this. See code example below,
which shows "normal" CR/LF. The basic problem is that emails that my form-to-mails generate using the mail() function consistently put in two CR/LF's for every apparent CF/ LF. How does this happen, how to fix the... Double line spaces that appear like this in the body? -Chuck $message ='Dear ' . Trim($fullname) .', Thank you for your interest in our product. Blah blah blah blah blah Sincerely, Joe Schmoe'; $headers .= 'From: Web server <w...@domainname.com>' . "\r\n"; $subject = 'Your posted message'; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The example above would generate a message that reads like: Dear Mr. Smith, Thank you for your interest in our product. Blah blah blah. Sincerely, Joe Schmoe. |