摘要:
1.使用 @RequestParam("username") 来对应参数名的时候,这个参数必须要传入,否则会报错。没加@RequestParam则可传可不传
@RequestMapping("/index")
public String index(@RequestParam("username") String username, String password) {
System.out.println(username);
System.out.println(password);
return "test/index";
} 阅读全文