Django: Getting Started Transcripts
Chapter: HTML Templates
Lecture: Django output types

Login or purchase this course to watch this video and the rest of the course contents.
0:00 You've written a couple of views now and your last one output a template.
0:05 The output from those views, a resulting HTML document usually contains references to other content that isn't HTML, things like images,
0:15 CSS and javascript. Django refers to these as static content content. That is just output. You need to refer to it, use URLs that reference it.
0:26 But Django doesn't really need to do anything with it and it typically doesn't come out of a view In a production situation,
0:33 you should have your static content served by a web server rather than by Django.
0:37 Django provides tools to simplify this process and manage your static files.
0:42 The development server will serve static files so you don't have to jump through hoops when
0:46 programming, but like many things with the development server, you should remember, it should only be used for development.
0:54 In addition to static content, Django has a third category of output media files. These are things the user has uploaded.
1:02 Like static files, the DEV server will serve media files, but you don't want Django dealing with these in production.
1:09 A later chapter, we'll talk more about uploads. Our web pages would be pretty boring without some static content to go with them.
1:17 So let's go set up some static content.


Talk Python's Mastodon Michael Kennedy's Mastodon