javaweb设置为servlet为默认首页的方法
servlet页面
@WebServlet(name = "ServletIndex", value="/index")
web.xml配置如下
<welcome-file-list> <welcome-file>index</welcome-file> </welcome-file-list>
访问域名默认首页就会访问/index
javaweb设置为servlet为默认首页的方法
servlet页面
@WebServlet(name = "ServletIndex", value="/index")
web.xml配置如下
<welcome-file-list> <welcome-file>index</welcome-file> </welcome-file-list>
访问域名默认首页就会访问/index