validate(schema,
on_error)
|
|
A form validating decorator
POST requests are validated against the specified FormEncode schema.
On success the converted form variables are stored in the wsgi environment
under the key "posterity.formvars". These values can also be accessed
from req.formvars .
If the validation fail, the original messages and the error messages
are stored in the wsgi environment and the request is re-run as a
GET-request. Forms on the resulting page will be filled with the values
stored in the environment.
|