文章目录
一、Spring MVC 功能拓展实现
(一)创建项目 - SpringMvcDemo2021
(二)复制第10讲项目内容到此项目
启动查看是否成功
访问浏览器: http://localhost:8080/toLoginPage
(三)写MVC配置文件,定义视图跳转
1.注释掉登录控制器里toLoginPage()方法上的注解
2.创建自定义MVC配置类
package net.lbj.lesson11.config;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import org.springframework.web.s