Esempio n. 1
0
def send_reset_email(user):
    token=user.get_reset_token()
    msg=Message('Password Reset Request',sender='*****@*****.**',recipients=[user.email])
    msg.body=f'''To reset your password. Visit the following Link:
{url_for('users.reset_token', token=token , _external=True)}

If you did not make this request.Kindly ignore the email'''
    mail.send(msg)
Esempio n. 2
0
def send_email(user):
    token = user.get_reset_token()
    print(app.config['MAIL_USERNAME'])
    msg = Message('Password Reset Request',
                  sender=str('*****@*****.**'),
                  recipients=[user.email])
    msg.body = "To reset your password, visit the following link:{}".format(
        url_for('users.reset_password', token=token, _external=True))
    mail.send(msg)
Esempio n. 3
0
def send_reset_email(user):
    token = user.get_reset_token()
    msg = Message('Password Reset Request',
                  sender='*****@*****.**',
                  recipients=[user.email])
    msg.body = f'''To Reset the Password, visit the following link:
	{url_for('users.reset_token', token = token, _external = True)}

	If you did not request to reset your password, then simply ignore this email and no changes will be made.'''
    mail.send(msg)
Esempio n. 4
0
def send_reset_email(user):
    token = user.get_user_token()
    msg = Message('Password reset link',
                  sender='*****@*****.**',
                  recipients=[user.email])
    msg.body = f'''To reset your password click on the below link 
        {url_for('users.reset_token',token=token,_external=True)}
    You if did not make this request ignore this. No changes will be made
    '''
    mail.send(msg)