Learn Flask: Jinja2 Templates and Forms
Turn Flask view functions into real web pages. Fill HTML templates with Jinja2 variables, filters, conditions, loops and shared layouts, then take input from visitors with plain HTML forms and with Flask-WTF, including validation, CSRF protection and flash messages.
- Intermediate level
- 2 modules
- 4 lessons
- 24 quiz questions
Syllabus
01Jinja2 TemplatesKeep HTML out of your Python. Render template files with variables and filters, branch and loop inside them, and share one page layout across the whole site.2 lessons
02FormsTake input from visitors. Read plain HTML forms with request.form and redirect after a POST, then let Flask-WTF define fields, validators and CSRF protection and report errors back to the page.2 lessons