springboot项目中添加了字体等文件后,页面无法识别,浏览器调试窗口报错如下:

Failed to decode downloaded font: http://localhost:8080/fonts/fontawesome-webfont.woff?v=4.4.0
OTS parsing error: incorrect file size in WOFF header Failed to decode downloaded font: http://localhost:8080/fonts/fontawesome-webfont.ttf?v=4.4.0
OTS parsing error: incorrect entrySelector for table directory

 解决方式,pom文件中增加如下内容,不对字体文件进行过滤即可:

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<configuration>
<nonFilteredFileExtensions>
<nonFilteredFileExtension>ttf</nonFilteredFileExtension>
<nonFilteredFileExtension>woff</nonFilteredFileExtension>
<nonFilteredFileExtension>woff2</nonFilteredFileExtension>
</nonFilteredFileExtensions>
</configuration>
</plugin>
</plugins>
</build>

 

最后不要忘记重启项目!!清空浏览器缓存!!

处理springboot OTS parsing error: Failed to convert WOFF 2.0 font to SFNT的更多相关文章

  1. Spring Boot + Bootstrap 出现"Failed to decode downloaded font"和"OTS parsing error: Failed to convert WOFF 2.0 font to SFNT"

    准确来讲,应该是maven项目使用Bootstrap时,出现 "Failed to decode downloaded font"和"OTS parsing error: ...

  2. 解决Spring Boot OTS parsing error: Failed to convert WOFF 2.0

    <build> <resources> <resource> <directory>${project.basedir}/src/main/resour ...

  3. 浏览器警告Failed to decode downloaded font和OTS parsing error: Failed to convert *** font to ***

    昨晚,在做一个自己感兴趣的东西时,发现浏览器报警告,Failed to decode downloaded font以及OTS parsing error: Failed to convert *** ...

  4. Spring Boot - Font Awesome OTS parsing error: Failed to convert 字体加载失败

    字体文件,加载不出来 解决方案  一 问题是Maven正在过滤字体文件并破坏它们. <resource> <directory>${project.basedir}/src/m ...

  5. OTS parsing error: invalid version tag woff和ttf文件被Filter拦截

    从服务器下载的字体文件放在本地,执行无法展示iconfont,浏览器控制台报出 Failed to decode downloaded font: http://127.0.0.1:8080/mhr/ ...

  6. 解决访问 jar 包里面的字体报错:OTS parsing error: incorrect file size in WOFF header

    前言:jar 包里面的字体加载,浏览器 console 中报警告信息,这里记录一下解决方案. 附:自己的一个 jar 包源码 https://github.com/yuleGH/querydb 错误问 ...

  7. linux下phpmailer发送邮件出现SMTP ERROR: Failed to connect to server: (0)错误

    转自:https://www.cnblogs.com/raincowl/p/8875647.html //Create a new PHPMailer instance $mail = new PHP ...

  8. linux 下 用phpmailer类smtp发送邮件始终不成功,提示:ERROR: Failed to co

    https://zhidao.baidu.com/question/509191264.html?fr=iks&word=PHPMailerSMTP+connect()+failed& ...

  9. phpmailer的SMTP ERROR: Failed to connect to server: 10

    请问,我在win7上学习使用phpmailer时,出现这种错误怎么处理啊? SMTP ERROR: Failed to connect to server: (0) SMTP connect() fa ...

随机推荐

  1. JavaScript--QuckStudy

    Day1: 初识JS: https://www.liaoxuefeng.com/wiki/1022910821149312 >打印: alert('我要学JavaScript!'); >J ...

  2. Jmeter安装及配置(含JDK安装)

    (一)java环境配置1.官网下载64位的jdkhttp://www.oracle.com/technetwork/java/javase/downloads/index.html 2.环境变量设置变 ...

  3. X86逆向7:特殊窗体的破解思路

    本章我们来看两个案例,这两个案例同样使用爆破的方式破解,但是与其他的程序不同,这个程序没有弹窗,提示成功或失败使用的是图片或是一个类似图片的窗体,本章将学习两个新的API函数的使用技巧. ------ ...

  4. 面试常考的js题目(二)

    1. 已知 fn 为一个预定义函数,实现函数 curryIt,调用之后满足如下条件: 返回一个函数 a,a 的 length 属性值为 1(即显式声明 a 接收一个参数) 调用 a 之后,返回一个函数 ...

  5. 关闭钩子(shutdown hook)的作用以及在Tomcat中的使用

    在很多实际应用环境中,当用户关了应用程序时,需要做一些善后清理工作,但问题是,用户有时并不会按照推荐的方法关闭应用程序,很有可能不做清理工作,例如在Tomcat的部署应用中,通过实例化一个Server ...

  6. asp.net 6.aspx页面

    1.aspx页面的头部 <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Us ...

  7. 基于C#实现与JY61姿态角度传感器通信

    产品介绍:  此六轴模块采用高精度的陀螺加速度计 MPU6050,通过处理器读取 MPU6050 的测量数据 然后通过串口输出,免去了用户自己去开发 MPU6050 复杂的 IIC 协议,同时精心的 ...

  8. JS基础_对象字面量

    <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title> ...

  9. JS基础_while的练习2

    <!DOCTYPE html> <html> <head> <meta charset="utf-8" /> <title&g ...

  10. Kendall tau距离(即两个内容相同的数组中逆序数对的数量)(算法》P220 第2.5.3.2小节)

    一组排列就是一组N个整数的数组,其中0~N-1的每个数都只出现一次.两个排列之间的 Kendall tau距离就是在两组排列中相对顺序不同的数对的数目.例如,0 3 1 6 2 5 4和1 0 3 6 ...