Monday, July 27, 2009

Form fields repopulating with default data.

I have a form field named user_first_name with no default value. When
a user named Fred completes this field correctly, but enters invalid
data in another field such as user_password, user_first_name is
automatically repopulated with "Fred" so Fred doesn't need to write
his first name again. Nice!

However, I also have a form field named user_birth_year with a default
value of "YYYY". Fred enters a valid birth year, but an invalid
password. Rather than saving his correct birth year, the field is
automatically repopulated with "YYYY".

How can this be avoided? Thanks.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: