开发者

What is the simplest way to send an email with an attachment using Python?

What is the simplest way to send an email with an mp3 attachment using Python? I've written scripts in the past which used a pipe to sendmail to send basic email messages, but I've never bothered with attachments 开发者_如何学Pythonbefore.

Thanks in advance.


Use email package. It's pretty simple.

In the URL I linked, you'll find straight examples on how to do just that.

Hope it helps.


You can also take a look at the python code used for: http://caspian.dotconf.net/menu/Software/SendEmail/

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜