“ python manage.py collectstatic”不起作用,我认为它可能不适用于任何文件,而fa-brands-400.eot恰好是第一个文件。
错误:
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<h5 id="headingone" data-target=".menu">View Comments</h5>
<div class="menu">
{% for i in item.piccomments.all %}
<p id="paratwo" style="margin:0px;"><strong>{{i.author}}</strong> said "{{i.text}}"</p>
{% endfor %}
</div>
settings.py应该位于根目录还是可以位于子目录中? 我的settings.py在结尾处有此
django.core.exceptions.SuspiciousFileOperation: The joined path (/Users/monica/music-emotion/static/webfonts/fa-brands-400.eot) is located outside of the base path component (/Users/monica/music-emotion/staticfiles)
答案 0 :(得分:0)
我遇到了刚删除的错误
STATICFILES_STORAGE ='whitenoise.storage.CompressedManifestStaticFilesStorage'
现在可以正常使用了。