I'm using 5.4 and for some reason I can not get my ajax form to hold onto the field values after a validation error has occurred. When a validation error occures all my fields are blanked out. Does anybody have any idea what might be causing this?
I have the following code snippet. <t:zone t:id="loginRegisterZone" id="loginRegisterZone"> <t:form t:id="registerForm" zone="loginRegisterZone"> <input t:type="textfield" t:id="firstName" placeholder="First Name" value="userProfile.firstName" class="input-sm"/> //additional fields <t:Submit class="btn btn-success" value="Register"/> </t:form> </t:zone> @Component(id = "registerForm") private Form registerForm; @Property private UserProfile userProfile; public void onPrepareFromRegisterForm() { userProfile = new UserProfile(); userProfile.setCreateDate(new Date()); } boolean onValidateFromRegisterForm() { if (password != null) { userProfile.setPassword(password); } if (getEmailExist(userProfile.getEmail())) { registerForm.recordError(""); alertManager.alert(Duration.TRANSIENT, Severity.ERROR, "Sorry, that email is not available, please try again."); return false; } UsernamePasswordToken token = new UsernamePasswordToken(userProfile.getEmail(), password); token.setRememberMe(true); currentUser.login(token); try { currentUser.login(token); } catch (AuthenticationException e) { throw new LockedAccountException(e); } return true; } --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org