Attempting to use popen with mailx

caseydemail-python at yahoo.com caseydemail-python at yahoo.com
Thu Sep 1 00:09:25 EDT 2005


I am trying to drive mailx using popen.

Here is what I am trying to do:

a=popen('mailx -s "test" 1234 at abc.com','w')
print a>>, "This is a test"
print a>>, "."
a.flush()

The email never sends, and I have to kill the
processes.  I am new to python, so I am sure I am
doing something wrong.

Can anyone help?

Thanks!




More information about the Python-list mailing list