Opened 12 years ago

Closed 12 years ago

#5359 closed (invalid)

trailing slash missing in documentation

Reported by: walshmj Owned by: nobody
Component: Documentation Version: master
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: yes
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


For example, say your MEDIA_ROOT is set to '/home/media', and upload_to is set to 'photos/%Y/%m/%d'. The '%Y/%m/%d' part of upload_to is strftime formatting; '%Y' is the four-digit year, '%m' is the two-digit month and '%d' is the two-digit day. If you upload a file on Jan. 15, 2007, it will be saved in the directory /home/media/photos/2007/01/15.

Change History (3)

comment:1 Changed 12 years ago by Adrian Holovaty

Can somebody verify that MEDIA_ROOT requires a trailing slash?

comment:2 Changed 12 years ago by Malcolm Tredinnick

I can't see how this would be true. Everywhere we refer to MEDIA_ROOT in the code and use it to create a pathname, we use os.path.join, which adds the directory separator between the components, if needed.

comment:3 Changed 12 years ago by Simon G. <dev@…>

Resolution: invalid
Status: newclosed

Ok, marking as invalid unless someone can reconfirm this.

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