<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Sat, 18 May 2013 10:22:43 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Jani Hartikainen's Blog: Validating Zend_Forms using model objects]]></title>
      <guid>http://www.phpdeveloper.org/news/12482</guid>
      <link>http://www.phpdeveloper.org/news/12482</link>
      <description><![CDATA[<p>
<i>Jani Hartikainen</i> has <a href="http://codeutopia.net/blog/2009/05/07/validating-zend_forms-using-model-objects/">posted a three-step process</a> to his blog about handling the information submitted into a Zend_Form instance with a model.
</p>
<blockquote>
Zend_Forms, models, validation and how they all work together is a tricky topic. There are many opinions and many ways to do it. This time I'll show you what I think could be the answer to validating forms without having to duplicate validation code both in a model class and in your form.
</blockquote>
<p>
He creates a simple model interface (with get, set, isValid and getMessages methods) and a validator extended from Zend_Validate_Abstract to pass the information back into the model through an isValid method call. The validator is then added to each element you want to use it on in the addElement call on the Zend_Form object.
</p>]]></description>
      <pubDate>Fri, 08 May 2009 10:27:30 -0500</pubDate>
    </item>
  </channel>
</rss>
