pycharm开发django项目 static报404解决方法

 

settings文件中确保有以下配置

# Static files (CSS, JavaScript, Images)
# https://docs.djangoproject.com/en/1.10/howto/static-files/
STATIC_URL = '/static/'
STATICFILES_DIRS = (
os.path.join(BASE_DIR, 'static'),
)

另外
DEBUG = True

posted on 2018-06-23 15:02  林肯公园  阅读(1115)  评论(0编辑  收藏  举报

导航