出现错误:

Failed to load resource: the server responded with a status of 404 ()

但是其他页面正常显示:

原因:

浏览器看一下: 

点开 看一下 请求链接:

Request URL: http://localhost:8080/emp/asserts/css/bootstrap.min.css 
 
明显 加了 请求关键字 emp 了. 
 
但是我们的资源路径全部放在 static 应该没有问题,拦截器如果存在问题,那其他页面也不可能正常显示<
 
 

处理办法:

加上反斜杠

  <script type="text/javascript" src="/asserts/js/jquery-3.2.1.slim.min.js"></script>
<script type="text/javascript" src="/asserts/js/popper.min.js"></script>
<script type="text/javascript" src="/asserts/js/bootstrap.min.js"></script>

或者使用thymeleaf @{}处理

 <script type="text/javascript" src="asserts/js/feather.min.js" th:src="@{/asserts/js/feather.min.js}"></script>

Spring Boot Failed to load resource: the server responded with a status of 404 ()的更多相关文章

  1. jsp中引入jquery报错:Failed to load resource: the server responded with a status of 404 (Not Found)

    问题描述: 今天自己在搭建spring.springMVC.hibernate框架,搭建完成后,在引入jquery时,发现jquery不管用.我的解决顺序是: 1.检查路径,发现路径没错,另外需要注意 ...

  2. 报错解决——Failed to load resource: the server responded with a status of 404 (Not Found) favicon.ico文件找不到

    Django项目开发完成后在本地运行没问题,但在推到服务器上后出现报错Failed to load resource: the server responded with a status of 40 ...

  3. 待解决:2bootstrap-cerulean.css Failed to load resource: the server responded with a status of 404 ()

    2bootstrap-cerulean.css Failed to load resource: the server responded with a status of 404 ()

  4. Failed to load resource: the server responded with a status of 404 (Not Found)

    Failed to load resource: the server responded with a status of 404 (Not Found) 报错情况:图标加载失败 原因分析:路径错误 ...

  5. ripple Failed to load resource: the server responded with a status of 404 (Not Found)

    在VS2015中使用Cordova + typescript开发中,遇到个问题. 在javascript console 中提示: Failed to load resource: the serve ...

  6. springmvc Failed to load resource: the server responded with a status of 404 (Not Found)

    jsp页面导入css.js提示上述问题. Spring对静态资源的请求做专门处理 <!-- 对静态资源的请求 --><mvc:resources location="/js ...

  7. SSM框架下 Failed to load resource: the server responded with a status of 404 (Not Found)错误

    这个错误提示的是js的引用路径有错: 1.检查应用路径是否正确(我的问题是路径是正确的但是去到页面就会提示404错误) 引用路径,最好都使用绝对路径 <script type="tex ...

  8. Failed to load resource: the server responded with a status of 404 (Not Found) favicon.ico文件找不到

      今天使用sublime以localhost方式打开html文件时(使用wamp环境提供一个Apache服务器,html文件存在于wamp环境的www文件夹下),出现favicon.ico文件找不到 ...

  9. glyphicons-halflings-regular.woff2:1 Failed to load resource: the server responded with a status of 404 (Not Found)解决Web部署 svg/woff/woff2字体 404错误

    问题:最近在IIS上部署web项目的时候,发现浏览器总是报找不到woff.woff2字体的错误.导致浏览器加载字体报404错误,白白消耗了100-200毫秒的加载时间. 原因:因为服务器IIS不认SV ...

随机推荐

  1. df命令、du命令、磁盘分区 使用介绍

    第4周第1次课(4月9日) 课程内容:4.1 df命令4.2 du命令4.3/4.4 磁盘分区 4.1 df命令 汇报磁盘空间使用情况,linux磁盘挂载点是无法直接访问的. df 和 df -h区别 ...

  2. 华为云&#183;寻找黑马程序员#海量数据的分页怎么破?【华为云技术分享】

    版权声明:本文为博主原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明. 本文链接:https://blog.csdn.net/devcloud/article/detai ...

  3. Python面试180道题

    版权声明:本文为CSDN博主「CSDN学院官方账号」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明. 原文链接:https://blog.csdn.net/csd ...

  4. Pycharm常见快捷键

    Ctrl+/注释(取消注释)选择的行 Shift + Enter开始新行 Ctrl + Enter智能换行 TAB Shift+TAB缩进/取消缩进所选择的行 Ctrl + Alt + I自动缩进行 ...

  5. I/O中断原理

    目录 I/O中断原理 前言 什么是中断 中断类型 硬件中断 软件中断 I/O中断流程 无中断 有中断 中断处理 相关文献 I/O中断原理 前言 在Windows内核原理-同步IO与异步IO和<高 ...

  6. 2018 ACM/ICPC 南京 I题 Magic Potion

    题解:最大流板题:增加两个源点,一个汇点.第一个源点到第二个源点连边,权为K,然后第一个源点再连其他点(英雄点)边权各为1,然后英雄和怪物之间按照所给连边(边权为1). 每个怪物连终点,边权为1: 参 ...

  7. BZOJ [HNOI2006]鬼谷子的钱袋

    1192: [HNOI2006]鬼谷子的钱袋 Time Limit: 10 Sec  Memory Limit: 162 MBSubmit: 5367  Solved: 3646[Submit][St ...

  8. POJ 2186 Popular cows(SCC 缩点)

    Every cow's dream is to become the most popular cow in the herd. In a herd of N (1 <= N <= 10, ...

  9. HDU3849-By Recognizing These Guys, We Find Social Networks Useful(无向图的桥)

    By Recognizing These Guys, We Find Social Networks Useful Time Limit: 2000/1000 MS (Java/Others)     ...

  10. Docker学习-jenkins+github实现持续集成和部署

    上一篇介绍了docker环境搭建,本篇继续深入,结合jenkins利用docker-compose容器编排简单介绍下如何实现个人学习的持续集成/部署. 本篇学习曲线: 1.安装/运行jenkins容器 ...