Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Net::SMTP and Attachments 3

Status
Not open for further replies.

V00D00

Technical User
Jul 11, 2005
78
US
I have seen many posts that talk around this subject but nothing that comes out and says this is the way.

Using Net::SMTP can you send an attachment?

My particular need is to send a text file.

As always... forgive me for ingorance.
 
there's nothing about how to send attachments in the documentation of the module.
 
You could try a different module, like Mail::Sender, where sending attachments is child's play.
 
I've always been prone to using Mime::Lite with Net:SMTP as the mailing engine. Net::SMTP can send e-mails with attachments, but it doesn't look like the module has matured to the point of handling it on it's own.

- George
 
I have taken your advice and installed Mail::Sender. It works perfectly. Thank you all for taking the time to help with the easy questions as much as you do the complicated ones.

VD
 
One of these days I'll actually finish building the module I started to do just what I posted earlier (sending e-mails with Mime::Lite and Net::SMTP), but I want to get it more solidified first.

- George
 
first: VERY nice work on Net::SMTP.

Second: Not quite true re wheel and re-invention thereof.

The dflt perl distn (5.8.x) comes with Net::SMTP pre-pkd - so it's always gonna be available if you have perl.
MIME::Lite is a post-install, and sometimes, you just cant get it past the SE's ( and there are lots of drakonian SE's still around - would someone *pls* retire these guys?).

However, I understand that Net::SMTP is low-level for MIME-level problems like attachments.

so, maybe a note wrt sending attachments in the docn - you got most of the basic MIME tokens in there anyway, so i dont see it as too much of a stretch?

and i totally realise that RTFM is the correct answer :)
thanks for listening guys.
mm
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top