Tag Archives: Layui 404 Error

[Solved] Layui 404 Error: Static resources cannot load layui.js and layui. css

Static resources cannot load layui.js and layui. css

Solution:

Add the following contents to the web.xml configuration file

<servlet-mapping>
    <servlet-name>default</servlet-name>
    <url-pattern>*.js</url-pattern>
</servlet-mapping>
<servlet-mapping>
    <servlet-name>default</servlet-name>
    <url-pattern>*.css</url-pattern>
</servlet-mapping>