Opened 5 years ago
Closed 5 years ago
#30576 closed Bug (worksforme)
Code not working on Django Tutorial part 6.
Reported by: | Javier Carrasco | Owned by: | nobody |
---|---|---|---|
Component: | Documentation | Version: | dev |
Severity: | Normal | Keywords: | django, tutorial, background, image |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | yes | UI/UX: | no |
Description
In the section "Adding a background-image" (Part 6 of Django tutorial) teaches how to add a background image by editing style.css as follows:
body { background: white url("images/background.gif") no-repeat; }
However, this won't work because it doesn't reference the actual location of the image file. The following change fixes the issue (add /static/):
body { background: white url("/static/images/background.gif") no-repeat; }
Change History (1)
comment:1 by , 5 years ago
Has patch: | unset |
---|---|
Resolution: | → worksforme |
Status: | new → closed |
Summary: | Code not working on Django Tutorial part 6 → Code not working on Django Tutorial part 6. |
Version: | 2.2 → master |
Note:
See TracTickets
for help on using tickets.
Tutorial 06 works for me. Probably you've made some mistakes with directories,
background.gif
should be insidepolls/static/polls/images
.