<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic PHP multipart mail not showing on Mac's in Everything else</title>
    <link>https://community.plus.net/t5/Everything-else/PHP-multipart-mail-not-showing-on-Mac-s/m-p/565089#M4716</link>
    <description>I'm sending some emails from PHP - &lt;PRE&gt;mail($to, $subject, $emailbody, $headers);&lt;/PRE&gt; using a &lt;B&gt;multipart&lt;/B&gt;, and most PC boys are fine, but it seems everyone using a Mac says nope can't see a thing stop sending me blank emails. So looking for anyone who's done this and got it working. The $emailbody is:&lt;BR /&gt;&lt;PRE&gt;YOUR EMAIL READER DOES NOT SUPPORT MULTI-PART DOCUMENTS&lt;BR /&gt;BLAH BALH BLAH&lt;BR /&gt;--PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY&lt;BR /&gt;Content-Type: text/plain; charset="iso-8859-1"&lt;BR /&gt;Content-Transfer-Encoding: 7bit&lt;BR /&gt;YOUR EMAIL READER DOES NOT SUPPORT HTML DOCUMENTS&lt;BR /&gt;BLAH BALH BLAH&lt;BR /&gt;--PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY&lt;BR /&gt;Content-Type: text/html; charset="iso-8859-1"&lt;BR /&gt;Content-Transfer-Encoding: 7bit&lt;BR /&gt;Here's a nice HTML document&lt;BR /&gt;&amp;lt;BR&amp;gt;&amp;lt;BR&amp;gt; So good that you can read it properly.&lt;BR /&gt;--PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY &lt;BR /&gt;&lt;/PRE&gt;&lt;BR /&gt;And the header is:&lt;BR /&gt;&lt;PRE&gt;Content-Type: multipart/alternative; boundary="PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY"&lt;BR /&gt;MIME-Version: 1.0&lt;BR /&gt;X-Mailer: PHP v4.3.9&lt;BR /&gt;From: Martin &amp;lt;martin@thisismartin.co.uk&amp;gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;BR /&gt;So what have I done wrong or is it just a few old Mac who's will never be able to read anything?</description>
    <pubDate>Fri, 28 Nov 2008 14:51:53 GMT</pubDate>
    <dc:creator>mar7t1n</dc:creator>
    <dc:date>2008-11-28T14:51:53Z</dc:date>
    <item>
      <title>PHP multipart mail not showing on Mac's</title>
      <link>https://community.plus.net/t5/Everything-else/PHP-multipart-mail-not-showing-on-Mac-s/m-p/565089#M4716</link>
      <description>I'm sending some emails from PHP - &lt;PRE&gt;mail($to, $subject, $emailbody, $headers);&lt;/PRE&gt; using a &lt;B&gt;multipart&lt;/B&gt;, and most PC boys are fine, but it seems everyone using a Mac says nope can't see a thing stop sending me blank emails. So looking for anyone who's done this and got it working. The $emailbody is:&lt;BR /&gt;&lt;PRE&gt;YOUR EMAIL READER DOES NOT SUPPORT MULTI-PART DOCUMENTS&lt;BR /&gt;BLAH BALH BLAH&lt;BR /&gt;--PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY&lt;BR /&gt;Content-Type: text/plain; charset="iso-8859-1"&lt;BR /&gt;Content-Transfer-Encoding: 7bit&lt;BR /&gt;YOUR EMAIL READER DOES NOT SUPPORT HTML DOCUMENTS&lt;BR /&gt;BLAH BALH BLAH&lt;BR /&gt;--PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY&lt;BR /&gt;Content-Type: text/html; charset="iso-8859-1"&lt;BR /&gt;Content-Transfer-Encoding: 7bit&lt;BR /&gt;Here's a nice HTML document&lt;BR /&gt;&amp;lt;BR&amp;gt;&amp;lt;BR&amp;gt; So good that you can read it properly.&lt;BR /&gt;--PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY &lt;BR /&gt;&lt;/PRE&gt;&lt;BR /&gt;And the header is:&lt;BR /&gt;&lt;PRE&gt;Content-Type: multipart/alternative; boundary="PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY"&lt;BR /&gt;MIME-Version: 1.0&lt;BR /&gt;X-Mailer: PHP v4.3.9&lt;BR /&gt;From: Martin &amp;lt;martin@thisismartin.co.uk&amp;gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;BR /&gt;So what have I done wrong or is it just a few old Mac who's will never be able to read anything?</description>
      <pubDate>Fri, 28 Nov 2008 14:51:53 GMT</pubDate>
      <guid>https://community.plus.net/t5/Everything-else/PHP-multipart-mail-not-showing-on-Mac-s/m-p/565089#M4716</guid>
      <dc:creator>mar7t1n</dc:creator>
      <dc:date>2008-11-28T14:51:53Z</dc:date>
    </item>
    <item>
      <title>Re: PHP multipart mail not showing on Mac's</title>
      <link>https://community.plus.net/t5/Everything-else/PHP-multipart-mail-not-showing-on-Mac-s/m-p/565090#M4717</link>
      <description>Mail is finicky. Have you tried it with a final -- (double hyphen, no space) after the last boundary?&lt;BR /&gt;Gabe</description>
      <pubDate>Fri, 28 Nov 2008 15:46:20 GMT</pubDate>
      <guid>https://community.plus.net/t5/Everything-else/PHP-multipart-mail-not-showing-on-Mac-s/m-p/565090#M4717</guid>
      <dc:creator>Gabe</dc:creator>
      <dc:date>2008-11-28T15:46:20Z</dc:date>
    </item>
    <item>
      <title>Re: PHP multipart mail not showing on Mac's</title>
      <link>https://community.plus.net/t5/Everything-else/PHP-multipart-mail-not-showing-on-Mac-s/m-p/565091#M4718</link>
      <description>IIRC you need to have some extra headers, along the lines of:&lt;BR /&gt;&lt;PRE&gt;&lt;BR /&gt;MIME-version: 1.0&lt;BR /&gt;Content-type: multipart/alternative;&lt;BR /&gt; boundary=--PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY&lt;BR /&gt;&lt;/PRE&gt;&lt;BR /&gt;Although personally I think HTML email is evil, different strokes for different folks I guess &lt;img class="lia-deferred-image lia-image-emoji" src="https://community.plus.net/html/@104CD63F9302A50EF5EC70FE32BB8AA1/images/emoticons/smiley.gif" alt="Smiley" title="Smiley" /&gt;</description>
      <pubDate>Fri, 28 Nov 2008 16:13:28 GMT</pubDate>
      <guid>https://community.plus.net/t5/Everything-else/PHP-multipart-mail-not-showing-on-Mac-s/m-p/565091#M4718</guid>
      <dc:creator>Ben_Brown</dc:creator>
      <dc:date>2008-11-28T16:13:28Z</dc:date>
    </item>
    <item>
      <title>Re: PHP multipart mail not showing on Mac's</title>
      <link>https://community.plus.net/t5/Everything-else/PHP-multipart-mail-not-showing-on-Mac-s/m-p/565092#M4719</link>
      <description>Hi Gabe,&lt;BR /&gt;After much fiddling I stumbled across the requirement to have a double hypen (--) at the end of the last boundaray statement. Thanks to gmail.com which was also as picky as the Mac users and now everyone can read all that I send them&amp;nbsp; &lt;img class="lia-deferred-image lia-image-emoji" src="https://community.plus.net/html/@104CD63F9302A50EF5EC70FE32BB8AA1/images/emoticons/smiley.gif" alt="Smiley" title="Smiley" /&gt;&lt;BR /&gt;&lt;PRE&gt;--PHP-alt-THISISMARTINLIVEBOOKINGCONTENTBOUNDARY--&lt;/PRE&gt;&lt;BR /&gt;I'm also sending the message in plain text so that all those can't / won't read HTML can still get the jist of what we're saying.&lt;BR /&gt;&lt;PRE&gt;$plaintext = ereg_replace ("&amp;lt;([^&amp;lt;&amp;gt;]*)&amp;gt;", "", $plaintext );&lt;BR /&gt;$plaintext = ereg_replace ("&amp;amp;pound;", "GBP ", $plaintext );&lt;BR /&gt;$plaintext = ereg_replace ("[\t]*","",$plaintext);	&lt;BR /&gt;$plaintext = ereg_replace ("\r[ \t\r\n\v\f]*\r","\r\n",$plaintext);&lt;/PRE&gt;&lt;BR /&gt;So all solved.... Onto the next problem now....</description>
      <pubDate>Sat, 29 Nov 2008 11:39:08 GMT</pubDate>
      <guid>https://community.plus.net/t5/Everything-else/PHP-multipart-mail-not-showing-on-Mac-s/m-p/565092#M4719</guid>
      <dc:creator>mar7t1n</dc:creator>
      <dc:date>2008-11-29T11:39:08Z</dc:date>
    </item>
  </channel>
</rss>

