MIME::Lite (or its cousin MIME::Entity) is definately the way to go here. And if you want to get a little bit fancier, you can provide a text version as well as an HTML version for those of us who hate receiving HTML email.
$msg = MIME::Lite->new( From => $from, To => $to, Subject => $subject, Type => 'multipart/alternative', ); $msg->attach( Type => 'text/html', Data => $html, ); $msg->attach( Type => 'text/plain', Data => $text, );
The content type of 'multipart/alternative' tells the browser it can choose between the two formats as they should contain the same information. It means a bit more work for you as you have to format a text version and an HTML version, but it will make your users happy.
- Cees
In reply to Re^2: email output using HTML format.
by cees
in thread email output using HTML format.
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |