Python+Flaskで、GETとPOSTのルーティングです。習うより慣れろって感じでしょうか。
参考サイト
Quickstart(Flask Documentation)
Flask view return error "View function did not return a response"(Stack Overflow)
from flask import Flask, render_template, request
def do_the_login():
return 'The do_the_login'
@app.route('/login', methods=['GET', 'POST'])
def login():
if request.method == 'POST':
return do_the_login()
else:
return render_template('login.html')
参考サイト
Quickstart(Flask Documentation)
Flask view return error "View function did not return a response"(Stack Overflow)