add validation to register page