I just finished to serve my pages online via apache. I see my webpage well, but when I try the admin, there is no css with it on the django admin page, just the html page. But my css webpage is displayed beautifully. Thanks!
my http.conf snippet:
WSGIPythonPath C:/Users/robin/web/etc/etc <Directory C:/Users/robin/web/etc/etc> <Files wsgi.py> Order deny,allow Allow from all </Files> </Directory> #Alias /robots.txt /path/to/mysite.com/static/robots.txt #Alias /favicon.ico /path/to/mysite.com/static/favicon.ico AliasMatch ^/([^/]*\.css) C:/Users/robin/web/etc/etc/static/styles/$1 #Alias /media/ /path/to/mysite.com/media/ Alias /static/ C:/Users/robin/web/etc/etc/static/ <Directory C:/Users/robin/web/etc/etc/static> Order deny,allow Allow from all </Directory> #<Directory /path/to/mysite.com/media> #Order deny,allow #Allow from all #</Directory> WSGIScriptAlias / C:/Users/robin/web/etc/etc/etc/wsgi.py <Directory C:/Users/robin/web/etc/etc/etc> <Files wsgi.py> Order allow,deny Allow from all </Files> </Directory>
my settings snippet:
STATIC_ROOT = 'C:/Users/robin/web/etc/static/' STATIC_URL = '/static/'
I created another directory for statics and already directed django to a directory where you can find statics. I edited and added the settings fragment above, kindly check it out. And they ran the collectstatic command, and it created three directories - admin, css and images. And copied all the statics from the project to this directory, even admin css and images in the admin directory. And the server also displays my css project well. But not from admin css. What am I missing? Please guide me.
Robin source share