O'Reilly logo

Core PHP Programming, Third Edition by Leon Atkinson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

24.5. HTML Email

An HTML email is a message presented in HTML instead of plain text. This allows control of colors and fonts for decoration, and it even allows the inclusion of images in a message. It's easy to send HTML email from your client, but it's not as easy from a PHP script. The key is to understand how to form MIME messages.

But first, you should decide whether the advantages of sending an HTML email fits your needs and whether you can do so ethically. The first reason to consider HTML email is the greater control over presentation you'll gain. Plaintext is fine when an email is a simple narrative, but if you want to present a table, you will have difficulty. Most GUI email clients use a variable-width font to display messages. As a ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required