how to build a small web app using the mvc pattern
TRANSCRIPT
![Page 1: How to build a small web app using the MVC pattern](https://reader030.vdocuments.site/reader030/viewer/2022032618/55b54fa8bb61eb172a8b45ac/html5/thumbnails/1.jpg)
Text
How to build a web appusing the MVC pattern
Samuel Fuentes for PyLadies - 2014/02/11
![Page 2: How to build a small web app using the MVC pattern](https://reader030.vdocuments.site/reader030/viewer/2022032618/55b54fa8bb61eb172a8b45ac/html5/thumbnails/2.jpg)
Samuel Fuentes, 2014 - @samufuentes
Agenda
How does the web work?
What does a web server do?
Building a small app
MVC Patterns: why and how
Other things to keep in mind
![Page 3: How to build a small web app using the MVC pattern](https://reader030.vdocuments.site/reader030/viewer/2022032618/55b54fa8bb61eb172a8b45ac/html5/thumbnails/3.jpg)
Samuel Fuentes, 2014 - @samufuentes
How does the web work
Client-server paradigm
HTTP
Request
Response
Response codes
![Page 4: How to build a small web app using the MVC pattern](https://reader030.vdocuments.site/reader030/viewer/2022032618/55b54fa8bb61eb172a8b45ac/html5/thumbnails/4.jpg)
Samuel Fuentes, 2014 - @samufuentes
What does a web server do
Waits for requests
Routes URL
Analyses request (GET, POST, parameters…)
Generates response (Gather data, process it, prepare content, present it, error handling)
![Page 5: How to build a small web app using the MVC pattern](https://reader030.vdocuments.site/reader030/viewer/2022032618/55b54fa8bb61eb172a8b45ac/html5/thumbnails/5.jpg)
Samuel Fuentes, 2014 - @samufuentes
MVC patternModel-view-controller
Model: handles data representation and logic
ORM
View: handles presentation
Template inheritance
Controller: handles input processing and flow control
![Page 6: How to build a small web app using the MVC pattern](https://reader030.vdocuments.site/reader030/viewer/2022032618/55b54fa8bb61eb172a8b45ac/html5/thumbnails/6.jpg)
Samuel Fuentes, 2014 - @samufuentes
Further conceptsForms
Redirects (3xx, 404, 500)
Cookies and sessions
Internationalisation and localisation
Security
Performance
Caching
Compression
![Page 7: How to build a small web app using the MVC pattern](https://reader030.vdocuments.site/reader030/viewer/2022032618/55b54fa8bb61eb172a8b45ac/html5/thumbnails/7.jpg)
Questions?
Samuel Fuentes VP Engineering Delivery Hero !
@samufuentes !