@InitBinder("user")
public void customizeBinding (WebDataBinder binder) {
SimpleDateFormat dateFormatter = new SimpleDateFormat("yyyy-MM-dd");
dateFormatter.setLenient(false);
binder.registerCustomEditor(Date.class, "dateOfBirth",
new CustomDateEditor(dateFormatter, true));
}