Forums

Indent problems

Hi

I am having indent problems when pasting into console/

def sendmail(content): 
    mail = smtplib.SMTP('smtp.gmail.com',587)
    mail.ehlo()  ##<- (first indent error)

If I take it out of the function it works OK.

Thanks (first day problems) p.s. already replaced tabs with spaces

What indent problems do you mean? Could you describe what you're trying to do and what happens in more detail, please?

Thanks Glenn.

The way I assume this works is that I upload a working python file in files tab then copy it and paste it into a console (py 2.7). Is this the way you execute the script to make sure it works on this platform? The program formats as I expected when I open and view the uploaded file.

--Steve

Never mind. Just saw way to run. Setting the run to Python 2.7 is something I am still searching for. (3 hours into the app sorry for the dumb questions)

http://help.pythonanywhere.com/pages/SaveAndRunPythonVersion

Thanks!