Really Simple Validation (RSV)
This small but powerful script lets you add javascript validation to your forms quickly and with very little effort. No programming experience is necessary, but it's fully extensible to allow programmers to augment the built-in validation rules with their own.
RSV comes in three flavours: as a standalone script, as a jQuery plugin and as a Prototype extension. All of the versions offer the same functionality, but I've separated the documentation and examples into sections to keep things clear. If you're unfamiliar with jQuery or Prototype you'll probably want to use the standalone script.
The script offers all the common validation routines offered by other validation scripts, but more importantly it supports "fringe" cases very well, with features such as:
- It allows you to apply multiple validation rules to the same field
- Allows for simple conditional logic (if field A == something, validation fields B, C and D)
- You can make up your own validation rules
- you can display the errors in literally any way you want, with 3 built-in standard ways to present them and the option to pass the errors to a custom error handler
- Lets you pass off control flow to your own onCompleteHandler function
- there's a PHP sister script available. You can literally copy & paste your validation rules to a PHP file to get server-side validation.