Jump to content

xittle

Members
  • Posts

    5
  • Joined

  • Last visited

xittle's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Fixed line endings, however I still have the smtp problem. I added some comments to my code to show where the problem is happening, #!/usr/bin/python3.6 import cgi import smtplib argv=cgi.FieldStorage(); #all commented lines other than this one are commented because they would return an error 500 #this line will not work s=smtplib.SMTP("mail.smtp2go.com", 2525); #this line depends on 5 s.login("BitDragon_Server",My_private_password"); #this line depends on 5 s.sendmail(argv["sen"].value,argv["rec"].value,argv["mess"].value); print("Content-type: text/html") print(); for element in argv.keys(): print(argv[element].value;
  2. I changed it to that after 2.7 didn't work, knowing on some machines the actual executable is named python27. It was a tweak that didn't work. I just changed it back, and it doesn't work as before. Partially Solved: I had tried 2.7 and 27 but didn't touch 3.6, which worked in the end. However, now the smtp part won't work.
  3. I am still having this problem even with appropriate syntax changes. I even commented out smtplib elements so that it just prints a list of argument values.
  4. Update: I tried krydos's solution but I'm getting a 500 internal server error. Help? Here is the python file (in cgi-bin): #!/usr/bin/env pythonimport cgiimport smtplibargv=cgi.FieldStorage();s=smtplib.SMTP("mail.smtp2go.com", 2525);s.login((my username),(my password));s.sendmail(argv["sen"],sys.argv["rec"],sys.argv["mess"]);print("Content-type: text/html")print();print(argv);
  5. I've been setting up a notification system for users on a service I have set up on heliohost, but have encountered a major issue. I am sending mail via a python script (mail.py), which takes several arguments and sends the mail, but my php cannot use shell_execute or system to run this script. What is a method that is allowed on heliohost?
×
×
  • Create New...