On Jun 14, 12:34 pm, Jason Brower <encomp...@gmail.com> wrote:
> It just times out.  No trace back that I can see.
> :/ interesting.
> Nope, web2py.com doesn't work either.

ok, so until your Firewall issues get resolved, here is the relevant
section from the appliance:

def email_user(sender,message,subject="group notice"):
    import smtplib
    fromaddr=sender
    toaddrs=[x.email for x in db().select(db.recipient.email)]
    msg="From: %s\r\nTo: %s\r\nSubject: %s\r\n\r\n%s"%(fromaddr,",
".join(toaddrs),subject,message)
    server = smtplib.SMTP('localhost:25')
    server.sendmail(fromaddr, toaddrs, msg)
    server.quit()

def index():
    form=SQLFORM(db.message,fields=
['your_name','your_email','your_message'])
    if form.accepts(request.vars,session):
       subject='cfgroup message from '+form.vars.your_name
       email_user(sender=form.vars.your_email,\
                  message=form.vars.your_message,\
                  subject=subject)
       response.flash='your message has been submitted'
    elif form.errors:
       response.flash='please check the form and try again'
    return dict(top_message=TOP_MESSAGE,form=form)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to web2py@googlegroups.com
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to