什么“这里不允许使用目录索引.”是指Django错误?
发布时间:2020-09-21 13:48:46 所属栏目:Python 来源:互联网
导读:我正在尝试调试我的Django应用程序中出现的这个奇怪的404错误. Page not found (404)Request Method: GETRequest URL: http://78.198.124.245/Directory indexes are not allowed here.Youre seeing this error because you have DEB
我正在尝试调试我的Django应用程序中出现的这个奇怪的404错误. Page not found (404) Request Method: GET Request URL: http://78.198.124.245/ Directory indexes are not allowed here. You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False,and Django will display a standard 404 page. 什么“这里不允许使用目录索引”.意思?什么是目录索引? 我用Google搜索,我发现所有结果都与提供静态文件有关.但是,我不认为我这样做.这个错误是什么意思? 解决方法检查settings.py文件中的STATIC_URL值.您希望该值是存储静态文件的子文件夹 – 通常为STATIC_URL =’/ static /’.(编辑:岳阳站长网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
相关内容
- python – 通过Curl向Flask发送JSON-Request [复制]
- python – Flask:后台线程看到一个非空队列为空
- 【Python】Python异常捕获与处理
- python – PySide GUI中的应用程序图标
- dict.viewkeys()返回的数据类型是什么? [python 2.7]
- 有时PyDev不会将.py文件识别为python源文件
- python – GTK标签包装在一个对话框中
- python – Opencv Homography矩阵H和Inverse H转换点没有得
- python – Pylint无效的函数名称
- python – django:django-tables2 DetailView CBV不会显示