How to map requests to HTML file in Spring MVC?

前端 未结 7 1145
你的背包
你的背包 2020-11-29 20:44

Basic configuration files looks unintuitive.

If I create simple hello world example, and then rename home.jsp to home.html and edit

相关标签:
7条回答
  • 2020-11-29 21:24

    Plain .html files are static and do not need a special ViewResolver. You should set up a static folder for your html pages as shown here.

    For example:

    <mvc:resources mapping="/static/**" location="/static/" />
    
    0 讨论(0)
提交回复
热议问题