Reply to Re: How to generate a HTML email using " instead of '

Your name:

Reply:


Posted by J.O. Aho on 11/29/05 11:49

Stefan Mueller wrote:
> I'd like to generate a HTML email with a PHP script. I do that with
> something like
> <?php
> $body = "<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.01 Transitional//EN'>
> <html>
> <head>
> <style type = 'text/css'>
> ...
>
> mail($to, $subject, $body, $headers);
> ?>
>
> It looks fine in Outlook but not in Lotus Notes. If I forward the email from
> Outlook to Lotus Notes it also looks fine in Lotus Notes.
> I think the problem is that I'm using
> <style type = 'text/css'>
> instead of
> <style type = "text/css">
>
> Therefore my question: How can I generate a HTML email with a PHP script
> using " instead of '?

<?php
$body = "<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.01 Transitional//EN'>
<html>
<head>
<style type = \"text/css\">
...

mail($to, $subject, $body, $headers);
?>

Keep in mind that HTML mail scores a lot more points in a spam check that
proper text mail, which can cause that the mail you send ain't accepted by the
MTA.



//Aho

[Back to original 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

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