springmvc does not intercept static resources, pictures cannot be displayed

After reading many people's blogs, the recommended method is

	<mvc:default-servlet-handler/>
	<mvc:annotation-driven ></mvc:annotation-driven>

But it is useless to me, css, jquery, jpg are not displayed,
and then add

<mvc:resources location="/WEB-INF/pages/css/" mapping="/css/**"/>
<mvc:resources location="/WEB-INF/pages/jquery/" mapping="/jquery/**"/> 
<mvc:resources location="/WEB-INF/pages/img/" mapping="/img/**"/>

This time it finally worked, but there is still no picture.
No matter how <mvc: resources location = "/ WEB-INF / pages / img /" mapping = "/ img / **" /> is changed, the picture cannot be displayed, in web.xml Adding some code will not work, and accidentally put the picture resource and the css file together and it works. ? ?
I still don't know why, can anybody explain it?

<img alt="" src="css/wall.jpg" >
Published 21 original articles · liked 0 · visits 721

Guess you like

Origin blog.csdn.net/D1124615130/article/details/104853183
Recommended