Skip to main content
Loading page…
Python Mastery
Chapter 32
Lesson 3 of 4
Forms, Sessions & Redirects
Contents
Notes
Tutor
Concept
The request Object — Reading Input
Loading activity…
Previous
1 / 9
Continue
Contents
Notes
Discussion
Tutor
49 min
9 activities
0 of 9 done
In this lesson
1
The request Object — Reading Input
2
The POST/Redirect/GET Pattern
3
Sessions — Signed Client-Side State
4
Flash Messages — One-Shot Notifications
5
CSRF — The Hidden Danger in HTML Forms
6
Why Redirect After POST?
7
request Attribute → Data Source
8
Describe Flask Sessions in Plain Terms
9
Senior Lab: Build, Run, and Review Evidence
Objectives
Learner can read form data with request.form and query strings with request.args
Learner can implement the POST/Redirect/GET pattern to prevent double-submission
Learner can store per-user state in signed cookies with Flask sessions
Learner can display one-time flash messages to the user
Learner can explain CSRF risk and how Flask-WTF addresses it
Further reading
Flask documentation
Chapter 32 · Web Apps with Flask
Routes & the Dev Server
Templates with Jinja2
Forms, Sessions & Redirects
A Real Flask App
Previous: Templates with Jinja2
Next: A Real Flask App