[PHP] Re: sending email with linefeeds

2002-09-07 Thread Manuel Lemos

Hello,

On 09/06/2002 12:10 PM, Kai Hinkelmann wrote:
 Hi,
 
 we are sending plain-text-emails from php not using the mail-command but
 with port-operations. Everything works fine BUT outlook 2000 eats the
 linefeeds. We tried several things: copying the header from an original
 (functional) email from outlook, sending with \n or \r\n to seperate
 header-info and so on... nothing works.
 
 All email-clients show the mails correct - outlook 2000 doesn't. Since other
 mails are shown correct, there MUST be a way, but we don't know, which.
 
 Who can help?

You may want to try this class that deals with line feeds properly 
according to the sending method.

http://www.phpclasses.org/mimemessage

It supports sending via mail() or SMTP which work under Windows, and 
sendmail and qmail that work only under Unix/Linux.

-- 

Regards,
Manuel Lemos


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




[PHP] Re: sending email with linefeeds

2002-09-06 Thread Erwin

Kai Hinkelmann wrote:
 Hi,

 we are sending plain-text-emails from php not using the mail-command
 but with port-operations. Everything works fine BUT outlook 2000 eats
 the linefeeds. We tried several things: copying the header from an
 original (functional) email from outlook, sending with \n or \r\n to
 seperate header-info and so on... nothing works.

 All email-clients show the mails correct - outlook 2000 doesn't.
 Since other mails are shown correct, there MUST be a way, but we
 don't know, which.

 Who can help?

Please paste a generated mail message (including header information), so we
can have a look at it...

Grtz Erwin



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




[PHP] Re: sending email with linefeeds

2002-09-06 Thread Kai Hinkelmann

I can't believe that I hit wrong buttons two times... so my answer for the
third time...

Thanks for your answer. Here is a genereted email:

Return-Path: [EMAIL PROTECTED]
Delivered-To: [EMAIL PROTECTED]
Received: (qmail 21481 invoked from network); 6 Sep 2002 15:47:03 -
Received: from notused.i-dea.de (HELO mail.e-h.de) (62.26.122.219)
  by ns.i-dea.de with SMTP; 6 Sep 2002 15:47:03 -
From:[EMAIL PROTECTED]
Subject:Testmail
Date:Fri, 6 Sep 2002 17:51:28
To:
Reply-To:[EMAIL PROTECTED]
MIME-Version:1.0
Content-Type:text/plain;
charset=iso-8859-1
X-UIDL: _7F!!bMh!!~Ea!9Bn!

first line
second line
third line

the three lines are seperated with 0d0a, just as outlook would seperate them
but the lines are not shown as a stack but as ONE line.

Kai

Erwin [EMAIL PROTECTED] schrieb im Newsbeitrag
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 Kai Hinkelmann wrote:
  Hi,
 
  we are sending plain-text-emails from php not using the mail-command
  but with port-operations. Everything works fine BUT outlook 2000 eats
  the linefeeds. We tried several things: copying the header from an
  original (functional) email from outlook, sending with \n or \r\n to
  seperate header-info and so on... nothing works.
 
  All email-clients show the mails correct - outlook 2000 doesn't.
  Since other mails are shown correct, there MUST be a way, but we
  don't know, which.
 
  Who can help?

 Please paste a generated mail message (including header information), so
we
 can have a look at it...

 Grtz Erwin





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




Re: [PHP] Re: sending email with linefeeds

2002-09-06 Thread Peter Janett

I spent a LOT of time several moths back trying to figure this one out.  It
worked fine in Outlook Express, but in Outlook, the whole message appeared
on a single line.  It only happened when my client filled out the form from
a Mac, which turned out to be the important clue.

The trick ended up being to remove all the carriage returns from the body of
the email.  Just like you, I played with lots of different mime type
headers, and tried to copy message source headers line by line, tab by tab,
etc.  If was very frustrating.  Don't know why exactly, but my theory was
that if Outlook saw any carriage returns, it displayed it as html formatted,
which made it all show up on one line.

Here's my code (it's in Perl, but you can adjust it to PHP simply), which
simply removes all carriage returns and replaces them with nothing in the
body of the message to be sent.
$FORM{'Message'} =~ s/\r//g;

HTH,

Peter Janett

New Media One Web Services

New Upgrades Are Now Live!!!
Windows 2000 accounts - Cold Fusion 5.0 and Imail 7.1
Sun Solaris (UNIX) accounts - PHP 4.1.2, mod_perl/1.25,
Stronghold/3.0 (Apache/1.3.22), MySQL 3.23.43

PostgreSQL coming soon!

http://www.newmediaone.net
[EMAIL PROTECTED]
(303)828-9882

- Original Message -
From: Erwin [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, September 06, 2002 9:20 AM
Subject: [PHP] Re: sending email with linefeeds


 Kai Hinkelmann wrote:
  Hi,
 
  we are sending plain-text-emails from php not using the mail-command
  but with port-operations. Everything works fine BUT outlook 2000 eats
  the linefeeds. We tried several things: copying the header from an
  original (functional) email from outlook, sending with \n or \r\n to
  seperate header-info and so on... nothing works.
 
  All email-clients show the mails correct - outlook 2000 doesn't.
  Since other mails are shown correct, there MUST be a way, but we
  don't know, which.
 
  Who can help?

 Please paste a generated mail message (including header information), so
we
 can have a look at it...

 Grtz Erwin



 --
 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