Hydrators Articles

Aggregate Hydrators for Sophisticated Object Hydration

April 14, 2015

Often times object hydration isn’t a simple matter, and requires a more nuanced, more sophisticated solution than the out-of-the-box options, available in Zend Framework, provide. Today we showcase one such solution - the Aggregate Hydrator.

Building and Executing SQL Queries In Zend

April 8, 2014

<p>Whilst there are many ways for building and executing <acronym title="Structured Query Language">SQL</acronym> queries in Zend Framework 2, the two that I usually use, and which are also used in the ZF2 manual, are <strong>closures</strong> and the selectWith function. <span style="line-height: 1.5em;">I previously </span><a style="line-height: 1.5em;" href="http://www.masterzendframework.com/tutorial/zend-db-sql-select-easy-where-clauses">wrote a three part series</a><span style="line-height: 1.5em;">, showing how to get started using the </span><strong style="line-height: 1.5em;">\Zend\Db\Sql</strong><span style="line-height: 1.5em;"> classes with Zend Framework 2, but I didn’t cover how to actually </span><strong style="line-height: 1.5em;">run them</strong><span style="line-height: 1.5em;">. So in today’s tutorial, let’s do that.</p>

Zend Framework 2 - Hydrators, Models and the TableGateway Pattern

April 15, 2013

<h2 id="synopsis">Synopsis</h2> <p>Zend Framework 2 comes packed with an assortment of new features and functionality and greatly streamlines how common scenarios, such as interacting with datasources and application configuration and caching are implemented.</p> <p>Whether it’s <a href="http://www.masterzendframework.com/tutorial/zf2-html5-form-field-introduction" title="Zend Framework 2 – The New HTML5 Form Fields">the new HTML5 form elements</a> and view helpers, the new implementation of <a href="http://framework.zend.com/manual/2.1/en/modules/zend.http.html">Zend\Http</a>, the Service Manager, the Event Manager or that <a href="http://www.masterzendframework.com/tutorial/zend-framework-2-modules-the-applications-heart">Modules are now first-class citizens</a> - you can’t help but see that it’s bursting at the seams.</p>