Send Email like request_reset_password from another controller/view

18 views
Skip to first unread message

Kike R.

unread,
May 4, 2015, 11:56:41 AM5/4/15
to web...@googlegroups.com
Hello,

I have a different view like  default/user and i need in this view/controller send a EMAIL like request_reset_password,  i have the email account to send the message but i don't know how i do this.


thx sorry for my bad english, only speak spanish.

黄祥

unread,
May 4, 2015, 12:29:00 PM5/4/15
to web...@googlegroups.com
why not just copy the user function in the controller 'default' and paste it on the other controller?

best regards,
stifan

Dave S

unread,
May 4, 2015, 8:07:27 PM5/4/15
to web...@googlegroups.com


On Monday, May 4, 2015 at 9:29:00 AM UTC-7, 黄祥 wrote:
why not just copy the user function in the controller 'default' and paste it on the other controller?


I'm not sure that was what was being asked.   I think KR was wanting to know how to send emails.

General reading:
<URL:http://www.web2py.com/books/default/chapter/29/08/emails-and-sms>
(there are a couple more hits in the book for "mail.send)

Some reading in the group for that:

<URL:https://groups.google.com/d/msg/web2py/uKShDBsxI3s/RWLAlGoF61cJ>
shows filling the auth fields.

<URL:"https://groups.google.com/d/msg/web2py/n-l0oxc5SwE/VsbG4Hd7VIUJ>
 recommendation to use scheduler because mail.send() is a blocking call.

<URL:https://groups.google.com/d/msg/web2py/8LN2jGVtOHg/OfLf1k_9xbsJ>
(if you are sending via gmail)

I haven't gotten around to trying any of this yet, so I can't answer any specific question, but there's more in the group archives, and most of the answer-providers are active here.

/dps

Reply all
Reply to author
Forward
0 new messages