Opened 7 years ago

Closed 7 years ago

#20173 closed Bug (worksforme)

tutorials: stylesheet in part 6 inconsistent with template in part 3

Reported by: kontextify@… Owned by: nobody
Component: Documentation Version: 1.5
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


In the "Write views that actually do something" section, the following template is created:

{% if latest_poll_list %}
    {% for poll in latest_poll_list %}
        <li><a href="/polls/{{ }}/">{{ poll.question }}</a></li>
    {% endfor %}
{% else %}
    <p>No polls are available.</p>
{% endif %}

In the "Adding a background image" section, the stylesheet includes the following rule:

body {
    background: white url("images/background.gif") no-repeat right bottom;

The template needs a <body> tag for this to actually work. A beginner might be confused!

Change History (2)

comment:1 Changed 7 years ago by kontextify@…

Summary: tutorials: stylesheet in tutorial06 inconsistent with template in tutorial03tutorials: stylesheet in part 6 inconsistent with template in part 3

comment:2 Changed 7 years ago by Tim Graham

Resolution: worksforme
Status: newclosed

Did you try this out? It works because browsers implicitly add the <body> tag when one isn't present. I think it's fine to omit it for simplicity.

Note: See TracTickets for help on using tickets.
Back to Top