Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: How to send mail containing multiple lines using Mail::Mailer?

by chargrill (Parson)
on Mar 14, 2007 at 17:37 UTC ( #604867=note: print w/replies, xml ) Need Help??


in reply to How to send mail containing multiple lines using Mail::Mailer?

Where's the code that fills $mailContents?

Does it perhaps look like this:

my $file = 'mailmessage'; open( my $fh, $file ) or die "couldn't read file - $!"; my $mailContents = <$fh>; close( $fh );

... or similar?

You might instead want:

my $file = 'mailmessage'; open( my $fh, $file ) or die "couldn't read file - $!"; my $mailContents; { local $/; $mailContents = <$fh>; } close( $fh );

HTH



--chargrill
s**lil*; $*=join'',sort split q**; s;.*;grr; &&s+(.(.)).+$2$1+; $; = qq-$_-;s,.*,ahc,;$,.=chop for split q,,,reverse;print for($,,$;,$*,$/)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://604867]
help
Chatterbox?
and !@monks...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (2)
As of 2016-12-03 02:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (52 votes). Check out past polls.