springmvc怎么重定向,从一个controller跳到另一个controller
1个回答
展开全部
return "forward:aaaa/bbbb.do";
return "redirect:aaaa/bbbb.do";
WEB-INF/web.xml 配置如下
<servlet>
<servlet-name>Spring-DispatcherServlet</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<init-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath:mescrow-appContext.xml</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>Spring-DispatcherServlet</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询