Exemple #1
0
def InsertUser():
    name = request.form.get('name')
    lastname = request.form.get('lastname')
    mail = request.form.get('mail')
    password = request.form.get('password')
    user = User("NULL", name, lastname, mail, password)
    user.InsertUser(name, lastname, mail, password)
    return redirect("/user")
Exemple #2
0
def confirmSignUp():
    name = request.form.get('name')
    lastname = request.form.get('lastname')
    mail = request.form.get('mail')
    password = request.form.get('password')
    confirmPassword = request.form.get('confirmPassword')
    if confirmPassword != password:
        return render_template('SignUp.html')
    user = User("NULL", name, lastname, mail, password)
    user.InsertUser(name, lastname, mail, password)
    if not user.idUser in session:
        session['idUser'] = user.idUser
    return redirect('/home')