Can't Get Email Interface Working
hlubenow
hlubenow2 at gmx.net
Sat Apr 7 19:59:53 EDT 2007
Eric Price wrote:
> Good grief! And they call a 722-line program "simple"?! LOL!
> I did what I need to do with a __one_line_shell_script__ LOL!
> Naw, if I have to go through all that, I'll skip on python this time
> around, thank you very much!
> Eric
Ok, "simplemail.py" is quite long. That's because it enables you to send
attachements and deals with character encoding and so on.
It is meant as a module (I didn't write it).
You can use it just like that:
-----------------------------------
from simplemail import Email
Email(
from_address = "sender at domain.net",
to_address = "receiver at domain.net",
subject = "Subject",
message = "Text of the message"
).send()
-----------------------------------
That's not that much longer than a single shell-command (and it's
Python :) ).
"simplemail.py" has been discussed here:
http://www.python-forum.de/topic-3158.html
but just in German.
H.
More information about the Python-list
mailing list