Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
All other things being equal, it’s best to give users immediate validation feedback as they type in an input field. Field validation is a common Ajax use case.
Figure 10–5 shows an example of Ajax field validation. The name component has a validator that checks to see whether the name contains an underscore; if so, the validator thows a validator exception containing an error message.