From bd8dbe3a8efde49e85da8ec5c9cc2d7d7d283268 Mon Sep 17 00:00:00 2001 From: Fudgerboy <91767657+Fudgerboy@users.noreply.github.com> Date: Tue, 9 Jul 2024 09:45:52 +0000 Subject: Tue, Jul 9, 2024, 2:45 AM -07:00 --- wk9/lect/froshims/app.py | 6 ++++++ wk9/lect/froshims/templates/index.html | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'wk9/lect/froshims') diff --git a/wk9/lect/froshims/app.py b/wk9/lect/froshims/app.py index de6ec44..f083e51 100644 --- a/wk9/lect/froshims/app.py +++ b/wk9/lect/froshims/app.py @@ -5,3 +5,9 @@ app = Flask(__name__) @app.route("/") def index(): return render_template("index.html") + +@app.route("/register", methods=["POST"]) +def register(): + + if not request.form.get("name"): + return "failure" diff --git a/wk9/lect/froshims/templates/index.html b/wk9/lect/froshims/templates/index.html index 53b5941..d9920da 100644 --- a/wk9/lect/froshims/templates/index.html +++ b/wk9/lect/froshims/templates/index.html @@ -4,7 +4,7 @@

Register

- +