Skip to content

Commit

Permalink
Fixed #2435 -- Fixed wording errors in Tutorial 4. Thanks, nicholas@a…
Browse files Browse the repository at this point in the history
…quarionics.com

git-svn-id: http://code.djangoproject.com/svn/django/trunk@3456 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information
adrianholovaty committed Jul 27, 2006
1 parent eb25411 commit c37a6fa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/tutorial04.txt
Expand Up @@ -198,15 +198,15 @@ By default, the ``object_detail`` generic view uses a template called
``vote()``.

Similarly, the ``object_list`` generic view uses a template called
``<app name>/<module name>_list.html``. Thus, rename ``poll/index.html`` to
``<app name>/<module name>_list.html``. Thus, rename ``polls/index.html`` to
``polls/poll_list.html``.

Because we have more than one entry in the URLconf that uses ``object_detail``
for the polls app, we manually specify a template name for the results view:
``template_name='polls/results.html'``. Otherwise, both views would use the same
template. Note that we use ``dict()`` to return an altered dictionary in place.

In previous versions of the tutorial, the templates have been provided with a context
In previous parts of the tutorial, the templates have been provided with a context
that contains the ``poll` and ``latest_poll_list`` context variables. However,
the generic views provide the variables ``object`` and ``object_list`` as context.
Therefore, you need to change your templates to match the new context variables.
Expand Down

0 comments on commit c37a6fa

Please sign in to comment.