note 57725 added to function.mail
| From: | doom_blaster at hotmail dot com | Date: | Wed, 12 Oct 2005 13:47:08 +0000 |
| Subject: | note 57725 added to function.mail | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-96895@lists.php.net to get a copy of this message | ||
OK you gave good exemples but none look good with Lotus Notes 6.X. I found some exelent code
compatible with Notes and others, the detailed solution is here :http://archivist.incutio.com/viewlist/css-discuss/37970
I have cleaned Rowan's text, this is my working code :
$boundary = md5(uniqid(time()));
$headers = 'From: ' . $from . "\n";
$headers .= 'To: ' . $to . "\n";
$headers .= 'Return-Path: ' . $from . "\n";
$headers .= 'MIME-Version: 1.0' ."\n";
$headers .= 'Content-Type: multipart/alternative; boundary="' . $boundary .
'"' . "\n\n";
$headers .= $body_simple . "\n";
$headers .= '--' . $boundary . "\n";
$headers .= 'Content-Type: text/plain; charset=ISO-8859-1' ."\n";
$headers .= 'Content-Transfer-Encoding: 8bit'. "\n\n";
$headers .= $body_plain . "\n";
$headers .= '--' . $boundary . "\n";
$headers .= 'Content-Type: text/HTML; charset=ISO-8859-1' ."\n";
$headers .= 'Content-Transfer-Encoding: 8bit'. "\n\n";
$headers .= $body_html . "\n";
$headers .= '--' . $boundary . "--\n";
$mailOk=mail('', $subject,'', $headers);
(Tested from Linux PHP4 to STMP Lotus Notes and Notes Client 6.5.1 & 5.? , it works with hotmail
too, I didn't test other client)
by DitLePorc
----
Manual Page -- http://www.php.net/manual/en/function.mail.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+57725
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+57725&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+57725&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+57725&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+57725&report=yes&reason=useless
Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+57725&report=yes&reason=non-english
Delete: already in docs -- http://master.php.net/manage/user-notes.php?action=delete+57725&report=yes&reason=already+in+docs
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+57725&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+57725&report=yes
Search -- http://master.php.net/manage/user-notes.php