Form login.html
:
<form method="POST">
<input type="text" placeholder="username" required>
<input type="password" placeholder="password" required>
<button type="submit">Sign in</button>
</form>
app.py
:
@app.route("/", methods=["GET", "POST"])
def login():
if request.method == "POST":
print(request.form) # prints empty dict
return render_template("login.html")