Summary

We've taken a whistle-stop tour of putting Python applications on the Web. We got an overview of web application architectures and their relationship to web servers. We looked at the utility of Python web frameworks, noting how they give us tools and structure to write better web applications more quickly, and help us integrate our applications with web servers.

We wrote a tiny application in the Flask web framework, we saw how it can help us elegantly manage our URL space, and how templating engines can help us cleanly manage the seperation of application logic and HTML. We also highlighted a couple of common potential security vulnerabilities— XSS and CSRF— and looked at some basic mitigation techniques.

Finally, we discussed web hosting ...

Get Learning Python Network Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.