Bug Notes-servlet&jsp---Front code error: Failed to decode downloaded font

Source: Internet
Author: User
1. Bug Description

Write code today when there is a problem, the front page of some small icons disappeared, after F12, found that the error message is as follows:

Failed to decode downloaded Font:http://localhost:8080/font-awesome-4.7.0/fonts/fontawesome-webfont

Of course, this is only one of them, because there are several icons can not be displayed, so there are several such error messages. 2. Bug Resolution

I first Google this error message, and did not find the correct solution, but one blogger said because the project used MAVEN, did not set the filter information in the Pom.xml, resulting in a bug, specific explanation click here.

This did not solve my problem, however, because my pom.xml and his format were not the same, and no interception was set up. But the blogger gave me an important clue to check my filter!!!

Sure enough, the problem appears in the filter, in the filter 's unfiltered URI field array, I just added css/js/img and so on, without adding this URI for the "font-awesome-4.7.0" library that displays the icon, resulting in a " font-awesome-4.7.0 "URI is blocked, causing a problem that the front page icon cannot be displayed.

So if your front-end page has this problem, and your MAVEN configuration is fine, it is recommended that you check your filter to see if there is a more filtered URI.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.