This was fixed in 1.78.3. Do you have an earlier version?
On Jun 7, 2:11 am, Paul Gerrard <[email protected]> wrote: > Hi, > > Using the auth/email functionality. I use the code below (extracted > from my default.py controller) and executing testmail function send > emails but it appears not to set up the "From:..." header in the > message. When the email arrives in my inbox, Outlook put the message > striaght into the junk folder, because it can't identify the sender. > (The same problem occurs with the user registration process). > > I've used some Python code and the smtplib code to send emails with > the same params and a From header and it works fine). > > Am I doing something wrong here? A bug? > > Suggestions gratefully received. > > Many thanks, > Paul. > > ++++ start ++++ > > from gluon.tools import Auth > from gluon.tools import Mail > > auth = Auth(globals(), db) > auth.define_tables() > # auth.settings.actions_disabled.append('register') > > mail = Mail(globals()) > mail.settings.server = 'localhost:25' > mail.settings.sender = '[email protected]' > auth.settings.mailer = mail > > def testmail(): > > auth.settings.mailer.send('[email protected]','hello','Test > Message',reply_to='[email protected]') > > return dict(mailer=auth.settings.mailer) > > +++ end +++

