Hi; I have this code: #!/usr/bin/python
import sys, os, string import cgitb; cgitb.enable() import cgi cwd = os.getcwd() dirs = string.split(cwd, '/') dirs = dirs[1:-1] backLevel = '/' + string.join(dirs, '/') sys.path.append(cwd) sys.path.append(backLevel) import string form = cgi.FieldStorage() // all the fields here subject = 'Order For Maya 2012' msg = 'First Name: %s\nLast Name: %s\nEmail Address: %s\nAddress2: %s, City: %s\nState: %s\nCountry: %s\nZip: %s\nPhone: %s\nFax: %s\nMessage: %s\n' % (firstNameText, lastNameText, emailText, addrText, addr2Te xt, cityText, stateText, countryText, zipText, faxText, messageText) ### LOOK AT THESE TWO LINES ourEmail = 'myemaila...@gmail.com' ourEmail = 'q...@xxx.com' def my_mail(): emailOne() emailTwo() def emailOne(): from simplemail import Email Email( from_address = ourEmail, to_address = emailText, subject = 'Thank you for your order!', message = msg ).send() def emailTwo(): from simplemail import Email Email( from simplemail import Email Email( # from_address = emailText, # to_address = ourEmail, from_address = ourEmail, to_address = emailText, subject = 'Order for Maya 2012', message = msg ).send() print '''Content-type: text/html <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title></title> <link rel="stylesheet" type="text/css" href="../../css/style.css"> </head> <body>''' my_mail() print ''' </body> </html> ''' Now what's absolutely crazy about this is that if I use my online form and enter my gmail address I get the email confirmations. However, if I get rid of that garbage value for ourEmail and use the other one which is the _very_same_gmail_address I get nothing!! No email. Ditto if I uncomment those lines in emailTwo and delete the next two lines. What on earth could be doing this??? TIA, Beno
-- http://mail.python.org/mailman/listinfo/python-list