INNER CODE UNIT · Python
home
tecladocode/web-dev-bootcamp · curriculum/section07/lectures/09_receive_form_data_flask/end/app.py:9
def home():
if request.method == "POST":
entry_content = request.form.get("content")
formatted_date = datetime.datetime.today().strftime("%Y-%m-%d")
print(entry_content, formatted_date)
return render_template("home.html")