The followings show a simple example using Webwork's Field Validators
Create the jsp page.
Create the action class.
Create the validator.xml.