Web Development with Django 6 - Third Edition
by Chris Guest, Mark Walker, Ben Shaw, Saurabh Badhwar, Bharath Chandra K S
8
Media Serving and File Uploads
Media files refer to extra files that can be added after deployment to enrich your Django application. Usually, they are extra images that you would use on your site, but any type of file (including video, audio, PDF, text, documents, or even HTML) can be served as media.
You can think of them as somewhere between dynamic data and static assets. They aren't dynamic data that Django generates on the fly, such as when rendering a template. They also aren't the static files that are included by the site developer when the site is deployed. Instead, they are extra files that can be uploaded by users or generated by your application for later retrieval.
Some common examples of media files (which you'll see in Activity ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access