I am using the PHP mail function this is the headers [COLOR=#000000][COLOR=#0000BB]$headers [/COLOR][COLOR=#007700]= [/COLOR][COLOR=#DD0000]'From: webmaster@example.com' [/COLOR][COLOR=#007700]. [/COLOR][COLOR=#DD0000]"\r\n" [/COLOR][COLOR=#007700]. [/COLOR][COLOR=#DD0000]'Reply-To: webmaster@example.com' [/COLOR][COLOR=#007700]. [/COLOR][COLOR=#DD0000]"\r\n" [/COLOR][COLOR=#007700]. [/COLOR][COLOR=#DD0000]'X-Mailer: PHP/' [/COLOR][COLOR=#007700]. [/COLOR][COLOR=#0000BB]phpversion[/COLOR][COLOR=#007700](); [/COLOR][/COLOR] Code (markup): I am facing issues with the qmail and am confused whether to use "\r\n" or just "\n" please share your comments on this issue.
[COLOR=#000000]echo [/COLOR][COLOR=#800000]'hi'[/COLOR][COLOR=#000000].[/COLOR][COLOR=#000000] PHP_EOL[/COLOR][COLOR=#000000];[/COLOR][COLOR=#000000] echo [/COLOR][COLOR=#800000]"hi\n"[/COLOR][COLOR=#000000];[/COLOR][COLOR=#000000] $headers [/COLOR][COLOR=#000000]=[/COLOR][COLOR=#800000]"From: "[/COLOR][COLOR=#000000].[/COLOR][COLOR=#000000] PHP_EOL [/COLOR][COLOR=#000000].[/COLOR][COLOR=#800000]"Reply-To: "[/COLOR][COLOR=#000000];[/COLOR] Code (markup):
From the PHP manual: "Multiple extra headers should be separated with a CRLF (\r\n). Note: When sending mail, the mail must contain a From header. This can be set with the additional_headers parameter, or a default can be set in php.ini. Failing to do this will result in an error message similar to Warning: mail(): "sendmail_from" not set in php.ini or custom "From:" header missing. The From header sets also Return-Path under Windows. Note: If messages are not received, try using a LF (\n) only. Some poor quality Unix mail transfer agents (emphasis mine) replace LF by CRLF automatically (which leads to doubling CR if CRLF is used). This should be a last resort, as it does not comply with » RFC 2822."