Controller:
@RequestMapping({"/user"})
?public void registerUser(User uu)
???throws Exception
?{
??System.out.println(uu.getPhone());
?}
jsp:
<form>
<input id="reg_username" name="phone" type="text" class="form-control" placeholder="手机号" datatype="m" errormsg="请输入手机号"/>
</form>
实体类:
public class User {
private String phone;//
public String getPhone() {
return phone;
}
public void setPhone(String phone) {
this.phone = phone;
}
}
SSM接收jsp实体类
原文地址:https://www.cnblogs.com/yanan7890/p/8137179.html