我尝试通过以下方式访问css文件:
<link rel="stylesheet" href="META-INF/resources/css/style.css" />
结构:
springhibernate
-META-INF
-recources
-css
-style.css
-img
-WEB-INF
-classes
-jsp
web.xml
application-context.xml
web.xml 部分:
<servlet>
<servlet-name>test</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>test</servlet-name>
<url-pattern>/</url-pattern>
</servlet-mapping>
如何引用 css 文件?