Where Are My Django Static Files?
When I view my Django admin (after firing up the python manage.py runserver
command), my admin section looks pretty & has CSS files in a static directory....somewhere.
When I look at the exact same admin area via Apache, it looks awful, 'cause the static files are nonexistent.
- http://localhost:8000/static/admin/css/base.css (run via Django, exists)
- http://loca开发者_开发技巧lhost/static/admin/css/base.css (run via Apache, doesn't exist!)
I'm assuming that the static CSS files are in some directory somewhere and the Django server can see them but Apache doesn't know where they are. So if I knew where Django keeps the CSS files, then I could put that path into the settings.py for static files. I have no clue where the files are being stored.... where are my Django static files?
For Django's admin static files, look in:
django > contrib > admin > media
精彩评论