Usually when we talk about developing Web sites, we’re talking about producing HTML. Of course, there’s a lot more to the Web than HTML; we use the Web to distribute data in all sorts of formats: RSS, PDFs, images, and so forth. So far we’ve focused on the common case of HTML production, but in this chapter we’ll take a detour and look at using Django to produce other types of content. Django has convenient built-in tools that you can use to produce some common non-HTML content:
- Comma-delimited (CSV) files for importing into spreadsheet applications.
- PDF files.
- RSS/Atom syndication feeds.
- Sitemaps (an XML format originally developed by Google that gives hints to search engines).
We’ll examine each of those tools a little later, but first we’ll cover the basic principles.