You are here: Re: mail() Oulook « PHP Language « IT news, forums, messages
Re: mail() Oulook

Posted by C. on 06/06/07 16:24

On 4 Jun, 19:39, misiek <michal_augustyn...@gazeta.pl> wrote:
> In Outlook does not parse correctly when email is sent as hmtl
>
> I use this code which I fountd on php.net
>
> I just spent a few hours working on getting a simple html formatted
> email to work on outlook. This is the end result:
>
> <?php
> $body="<em>HTML</em> formatted <strong>Message</strong";
>
> $headers = "From: i...@example.com \r\n";
> $headers .= "Content-Type: text/html; charset=ISO-8859-1 ";
> $headers .= "MIME-Version: 1.0 ";
> /*notice there aren't any \r\n after the second two header additions.
> This is what made this version work correctly*/
> mail("j...@example.com", "An HTML Message", $body, $headers);
> ?>
>
> the body shows up as a text/plain


Outlook is broken in many regards, but this is not one of them. Try
viewing the source of an email which seems to behave correctly in
Outlook. You should find that it complies with rfc2183 - i.e. the
content-disposition on the HTML MIME section is inline.

C.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация