Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

MIME::xxx sending mail with duplicate discription

by opensourcer (Monk)
on Feb 22, 2011 at 18:36 UTC ( #889644=perlquestion: print w/replies, xml ) Need Help??
opensourcer has asked for the wisdom of the Perl Monks concerning the following question:

The MIME::Lite::TT::HTML is sending the description two times in a mail (two times what I have typed from hello to regards, one as plain text and one in html). Below is the code.
my ( $myhash ) = shift; $params{Date} = $myhash->{DATEPOSTED}; $params{Title} = $myhash->{TITLE}; $msg = MIME::Lite::TT::HTML->new( From => '', To => '', Subject => $myhash->{TITLE}, Template => { html => 'sometemp.', }, TmplOptions => \%options, TmplParams => \%params, ); # Set our content type properly #$msg->attr("content-type" => "multipart/mixed"); #$msg->attr("content-type" => "text/html"); # Attaching resume $msg->attach( Type => 'application/doc', Path => 'attachments', Filename => 'books.doc', Disposition => 'attachment', );

Replies are listed 'Best First'.
Re: MIME::xxx sending mail with duplicate discription
by Corion (Pope) on Feb 22, 2011 at 18:41 UTC

    I would assume that this is by design, as there are mail readers that don't understand (or render) HTML. Also, the code of MIME::Lite::TT::HTML seems to actively parse out the text from HTML if no text is given.

    Why do you consider that a problem?

      Resolved issue by adding  text    =>  'Empty' empty file, to Template :)
        If by "resolved" you mean giving people a blank page if they can't render HTML or choose not to. Good way to get flagged as spam...

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://889644]
Approved by ikegami
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (9)
As of 2018-04-25 12:52 GMT
Find Nodes?
    Voting Booth?