Re: Not a Clue

From: Date: Mon, 12 Jun 2000 01:26:57 +0000
Subject: Re: Not a Clue
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-1582@lists.php.net to get a copy of this message
Dan Ellis wrote: > Does any one have an idea how to send html formatted email using > php..... have had no luck with the mail command just sends it tags > and all...<html>etc. You appear to be using Outlook, which is a severely limited mail client. Use something else & view the source of an HTML message. What you'll find is a couple of message headers that need to be sent: MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_000B_01BFD3DF.58F3BE80" Once you've sent those headers, all you need is to send something to tell the mail client where the next section starts so you can emit the appropriate Content-Type information: ------=_NextPart_000_000B_01BFD3DF.58F3BE80 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi All, Does any one have an idea how to send html formatted email using = php..... have had no luck with the mail command just sends it tags and = all...<html>etc. Thanks Dan Ellis ------=_NextPart_000_000B_01BFD3DF.58F3BE80 Content-Type: text/html; Content-Transfer-Encoding: bloated-unprintable <HTML> <BODY> <BLINK>This is a profoundly annoying message</BLINK> </BODY> </HTML> ------=_NextPart_000_000B_01BFD3DF.58F3BE80-- You could send the Content-Type header directly and avoid all mention of MIME but that'd be extremely rude unless the recipient had requested HTML email. For details, check the RFCs: ftp://ftp.isi.edu/in-notes/rfc2045.txt ftp://ftp.isi.edu/in-notes/rfc2046.txt ftp://ftp.isi.edu/in-notes/rfc2047.txt ftp://ftp.isi.edu/in-notes/rfc2048.txt If you just want to kludge something together quickly, take a look at http://hotwired.lycos.com/webmonkey/98/08/index3a.html.

« previous php.general (#1582) next »