Where do you do the data validation?
Hi,
I am trying to figure out a good architecture concerning data validation in reused components (e.g. you can add an register an end user via HTML-Form in the admin backend, html-form in some end user front end, webservice and mobile interface). The aim is to define validation rules and control the incoming data stream only once (probably as near to the business logic as possible).
Has anybody figured out a good way to do this with ZF? Probably one would use Zend Validate in the model classes and pass back messages to the SOAP/HTML-Views. I am yet not sure how this concept can interact with Zend Forms, how can I pass the validation messages to Zend Forms properly.
I am not using Zend MVC, but any best practise based on Zend MVC is interesting as well...
Dorthe
|