默认的Django 1.5管理CSS不工作 [英] Default Django 1.5 admin css not working

查看:115
本文介绍了默认的Django 1.5管理CSS不工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚安装在EC2上我的Django 1.5应用程序,目前该网站的/管理部分没有CSS。有没有一种方法,我可以配置此?

I just installed my django 1.5 app on ec2 and right now the /admin portion of the site doesn't have css. Is there a way that I can configure this?

只需添加到这个位于下面的文件夹中的css文件: /usr/local/lib/python2.6/dist-packages/django/contrib/admin/static/admin/css $

Just to add to this the css files are located in the following folder: /usr/local/lib/python2.6/dist-packages/django/contrib/admin/static/admin/css$

推荐答案

你是怎么配置的?对于管理应用程序加载静态文件,你需要创建在你的应用程序的静态目录的符号链接。你这样做?

How did you configure it? For admin app to load static files, you need to create a symbolic link inside your app's static directory. Have you done this?

的ls -l <​​/ code>应该给这样的:

ls -l should give something like:

admin -> /usr/local/lib/python2.6/dist-packages/django/contrib/admin/media

这篇关于默认的Django 1.5管理CSS不工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆