简体   繁体   English

加载资源失败:服务器响应状态为 404(未找到) - JavaScript

[英]Failed to load resource: the server responded with a status of 404 (Not Found) - JavaScript

Im working on learning JavaScript at the moment and don't fully understand the error in my console.我目前正在学习 JavaScript 并且不完全理解我的控制台中的错误。 I'm not working on anything too complicated and when following tutorials, I never have issues.我没有做任何太复杂的事情,在学习教程时,我从来没有遇到过问题。 It's always when I try to practice a project on my own.当我尝试自己练习一个项目时,总是如此。 My file structure follows as:我的文件结构如下:

Task List
 -index.html
 -styles.css
 -app.js

I've seen on similar questions that it's an issue when it comes to linking other folders but my css and js are both being added correctly.我在类似的问题上看到,在链接其他文件夹时这是一个问题,但我的 css 和 js 都被正确添加。

Console.log error Console.log 错误

It's not founding the fonts ( error 404 ), try to add them or delete the fonts import.它没有创建 fonts错误 404 ),尝试添加它们删除 fonts导入。

So you copy pasted your html from a place that were using fonts, or you are not providing us a full project file structure.因此,您从使用 fonts 的地方复制粘贴了 html,或者您没有向我们提供完整的项目文件结构。

If you would like to use an icon library , you should import it , using a CDN or downloading them , those are fonts files.如果您想使用图标库,您应该导入它使用 CDN 或下载它们,这些是 fonts 文件。 Follow the instructions in the project website, like FontAwesome .按照项目网站中的说明进行操作,例如FontAwesome

So:所以:

  1. You are trying to directly use the font in the styles , or...您正在尝试直接使用 styles 中的字体,或者...
  2. You are using an icon library class that implicitly relies on any of those fonts .您正在使用一个图标库 class 隐式依赖于任何这些 fonts

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 程序无法加载无法加载资源:服务器以404(未找到)状态响应 - Program will not load Failed to load resource: the server responded with a status of 404 (Not Found) Node.js服务器:无法加载资源:服务器以状态404(未找到)响应 - Nodejs server: Failed to load resource: the server responded with a status of 404 (Not Found) 加载资源失败:服务器响应状态为 404(未找到)? - Failed to load resource: the server responded with a status of 404 (Not Found)? 加载资源失败:服务器响应状态为404(未找到) - getting Failed to load resource: the server responded with a status of 404 (Not Found) Rails ajax:无法加载资源:服务器以状态404(未找到)响应 - Rails ajax: Failed to load resource: the server responded with a status of 404 (Not Found) 加载资源失败:服务器以 404(未找到)状态响应 nodejs - Failed to load resource: the server responded with a status of 404 (Not Found) with nodejs Apache Cordova:“无法加载资源:服务器以404(未找到)状态响应” - Apache Cordova: “Failed to load resource: the server responded with a status of 404 (Not Found)” 加载资源失败:服务器响应状态为404(未找到)。 与在caph ajax - Failed to load resource: the server responded with a status of 404 (Not Found). with ajax in caph JS / AJAX无法加载服务器响应的资源,状态为404(未找到) - JS/AJAX failed to load resource the server responded with a status of 404 (not found) ReactJS - 加载资源失败:服务器响应状态为 404(未找到) - ReactJS - Failed to load resource: the server responded with a status of 404 (Not Found)
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM