logo       

RE: Mail Headers problem.......: msg#03583

php.general

Subject: RE: Mail Headers problem.......

dunno if this helps, but try using "\r\n" instead of just "\n" when you
create $headers

-----Original Message-----
From: CDitty [mailto:mail@xxxxxxxxxxxxxxxx]
Sent: Friday, May 24, 2002 1:20 PM
To: php-general@xxxxxxxxxxxxx
Subject: [PHP] Mail Headers problem.......


I am writing a small email logging / forwarding script and am having
problems with the headers. I am successfully getting the MIME-Version and
Content-type, but when I insert them into the forwarded email message, the
headers show within the email itself. Below is the code I am using.

$to = "$user_email[0]";
$subj = "$Subject";
$msg = "$Message";

$headers = "From: $From[1]\n";
$headers .= "$Mime_Version\n";
$headers .= "$Content_Type\n";
mail($to, $subj, $msg, $headers);

This is what the email looks like.

Return-Path: <mail>
Received: (from mail@localhost)
by redhotsweeps.com (8.9.3/8.9.3) id VAA27003;
Thu, 23 May 2002 21:23:51 -0500
Date: Thu, 23 May 2002 21:23:51 -0500
Message-Id: <200205240223.VAA27003@xxxxxxxxxxxxxxxx>
To: XXXXXXX@xxxxxxxxxxxxxxxx
Subject: test
From: XXXXXXX@xxxxxxxxxxxxxxxx
Status:

Content-type: text/plain; charset="us-ascii"; format=flowed

test 1234


Can anyone give me any tips?

Thanks

CDitty




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise