<?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>Thu, 24 May 2012 20:39:20 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Till Klampaeckel's Blog: Zend Framework: CRUD]]></title>
      <guid>http://www.phpdeveloper.org/news/17988</guid>
      <link>http://www.phpdeveloper.org/news/17988</link>
      <description><![CDATA[<p>
In <a href="http://till.klampaeckel.de/blog/archives/183-Zend-Framework-CRUD.html">this new post</a> to his blog <i>Till Klampaeckel</i> shares a Zend Framework "base" controller that makes it easier to do the usual CRUD (Create, Read, Update, Delete) operations in an application.
</p>
<blockquote>
I think it took me (or us) a couple attempts to get this right - let me introduce you to Zf_Crud, a CRUD controller for the Zend Framework. [...] Zf_Crud aims to provide you with an interface for any table possible - think of it as a phpMyAdmin more tailored towards your data and (thanks to Twitter Bootstrap and the <a href="https://github.com/easybib/EasyBib_Form_Decorator">Easybib_Form_Decorator</a>) prettier!
</blockquote>
<p>
He <a href="http://till.klampaeckel.de/blog/archives/183-Zend-Framework-CRUD.html">shows how to install and use it</a> (via PEAR or Composer) and an example of a controller extending it. You can <a href="https://github.com/lagged/Zf_Crud/downloads">find the code here</a> on github, ready to clone and try out.
</p>]]></description>
      <pubDate>Tue, 22 May 2012 10:07:20 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Marcelo Gornstein's Blog: Making your ivr nodes (call) flow with PAGI]]></title>
      <guid>http://www.phpdeveloper.org/news/17955</guid>
      <link>http://www.phpdeveloper.org/news/17955</link>
      <description><![CDATA[<p>
<i>Marcelo Gornstein</i> has returned to his "IVR with PHP" series in <a href="http://marcelog.github.com/articles/making_your_ivr_nodes_call_flow_with_pagi_and_php_asterisk.html">this latest post</a> (see others <a href="http://phpdeveloper.org/news/17776">here</a> and <a href="http://phpdeveloper.org/news/17613">here</a>). In this new post he shows you how to create a full flow of interaction for your callers:
</p>
<blockquote>
The <a href="http://marcelog.github.com/articles/pagi_node_call_flow_easy_telephony_application_for_asterisk_php.html">last article</a> was about how to create call flow nodes for asterisk, using pagi and php, to easily create telephony applications. It's now time to add a layer on top of it, and create a complete call flow with several nodes.
</blockquote>
<p>
He talks about NodeControllers to control execution flow, results from their execution, available actions and an example of creating a controller and adding nodes. He builds on this simple controller and shows how to handle a few actions including responding to user feedback, adding multiple menu options and some more complex logic using a closure to contain the functionality.
</p>]]></description>
      <pubDate>Mon, 14 May 2012 12:09:50 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Evan Coury's Blog: Module-specific layouts in Zend Framework 2]]></title>
      <guid>http://www.phpdeveloper.org/news/17944</guid>
      <link>http://www.phpdeveloper.org/news/17944</link>
      <description><![CDATA[<p>
<i>Evan Coury</i> has a new Zend Framework 2 related blog post looking at how to use <a href="http://blog.evan.pro/module-specific-layouts-in-zend-framework-2">module specific layouts</a> in your application (even though, technically, it's more related to the controller).
</p>
<blockquote>
There's really no such thing as "module-specific" anything in ZF2, so what we're really talking about is the topmost namespace of the controller being dispatched. So in the case of MyModuleControllerSomeController, the topmost namespace would be MyModle. In most cases, this will be the name of a given module.
</blockquote>
<p>
He gives a quick piece of sample code showing a "Module" class that attaches an event on the dispatch of its request. Inside this event, he grabs the controller (target) and updates the layout via a call to the "layout" method. This is all handled in the "init" method of the module, so it should "just work" when the module is used.
</p>]]></description>
      <pubDate>Fri, 11 May 2012 08:07:44 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[PHPMaster.com: REST - Can You do More than Spell It? Part 2]]></title>
      <guid>http://www.phpdeveloper.org/news/17912</guid>
      <link>http://www.phpdeveloper.org/news/17912</link>
      <description><![CDATA[<p>
On PHPMaster.com today they've posted their series on "<a href="http://phpmaster.com/rest-can-you-do-more-than-spell-it-2/">speaking REST</a>" (<a href="http://phpdeveloper.org/news/17881">part one is here</a>), developing a PHP-based RESTful framework.
</p>
<blockquote>
In the <a href="http://phpmaster.com/rest-can-you-do-more-than-spell-it-2/rest-can-you-do-more-than-spell-it-2">first article</a> of his series, David explained how REST is more than an architectural pattern. It's a set of guiding principles that, if followed, can help you write scalable and robust applications. In the following articles, David will resume the discussion by looking at REST from the client-side of the equation. In this article though I'd like to focus on the server-side. You'll learn how to shift your thinking from the action-focused mindset that's prevalent in web development today to a more RESTful, resource oriented, approach, and see one way to structure your code and route URI requests in PHP.
</blockquote>
<p>
He talks about the change in mindset it takes to create an effective, resource-focused RESTful service and shows some of the initial steps towards getting it all down in code (based on a simplified "front controller" that routes the request appropriately). The resources are defined as classes (like the "Restaurant" in their example) which then handles the type of request based on the request type (GET, POST, etc).
</p>]]></description>
      <pubDate>Fri, 04 May 2012 13:02:14 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Rob Allen's Blog: Returning JSON from a ZF2 controller action]]></title>
      <guid>http://www.phpdeveloper.org/news/17748</guid>
      <link>http://www.phpdeveloper.org/news/17748</link>
      <description><![CDATA[<p>
In a new post to his blog <i>Rob Allen</i> shows how you can return JSON data <a href="http://akrabat.com/zend-framework-2/returning-json-from-a-zf2-controller-action/">directly back from a controller</a> in a Zend Framework 2 application.
</p>
<blockquote>
The new view layer in Zend Framework 2 can be set up to return JSON rather than rendered HTML relatively easily. [...] Firstly we need to set up the view's JsonStrategy to check to a situation when returning JSON is required and then to render out JSON for us.
</blockquote>
<p>
This "JsonStrategy" does some of the hard work for you - detecting when the client is requesting a JSON response and looking at the data coming into the view to see if it's JSON. He shows how to implement it in a sample module using the "onBootstrap" module and how to force a return of the JsonModel even when JSON isn't requested (useful for a consistent interface).
</p>]]></description>
      <pubDate>Thu, 29 Mar 2012 08:55:39 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Lorna Mitchell's Blog: Building A RESTful PHP Server: Routing the Request]]></title>
      <guid>http://www.phpdeveloper.org/news/17433</guid>
      <link>http://www.phpdeveloper.org/news/17433</link>
      <description><![CDATA[<p>
<i>Lorna Mitchell</i> is back with a second installment in her "Building a RESTful PHP Server" series with <a href="http://www.lornajane.net/posts/2012/building-a-restful-php-server-routing-the-request">this new post</a> about handling and routing the incoming requests. (You can find the first part about working with the request <a href="http://phpdeveloper.org/news/17418">here</a>)
</p>
<blockquote>
This is the second part of a series, showing how you might write a RESTful API using PHP. This part covers the routing, autoloading, and controller code for the service, and follows on from the first installment which showed how to parse the incoming request to get all the information you need.
</blockquote>
<p>
She shows how to grab the controller name from the incoming request (based on her previous code), create the object for it and execute the requested action name. Also included is a sample autoloader and a basic controller - a UsersController with "getAction" and "postAction" 
 methods for responding to GET and POST requests.
</p>]]></description>
      <pubDate>Mon, 23 Jan 2012 11:14:11 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Kevin Schroeder's Blog: Call for webinars (Zend)]]></title>
      <guid>http://www.phpdeveloper.org/news/17412</guid>
      <link>http://www.phpdeveloper.org/news/17412</link>
      <description><![CDATA[<p>
<i>Kevin Schroeder</i> is <a href="http://www.eschrade.com/page/looking-for-some-webinars">looking for suggestions</a>. He wants to know what the PHP community wants to hear about in upcoming webinars from <a href="http://zend.com">Zend</a>.
</p>
<blockquote>
Just wrapped up a call working on our webinar schedule for the year.  We've got a bunch of ideas but we'd like to also get your input as well.  Yes, I know y'all want ZF2 webinars.  We have that down.  I would also like to do an HTML5 and mobile webinar but I need an SME (Subject Matter Expert) for that. [...] I would also love to have webinars on how to use various API's, even if there is not native PHP support.  So, what kinds of webinars do you want?
</blockquote>
<p>
Leave your suggestions <a href="http://www.eschrade.com/page/looking-for-some-webinars#comments">in his comments</a> along with one already suggesting a "Why PHP?" checklist of sorts to help encourage companies/employers to go with the language.
</p>]]></description>
      <pubDate>Wed, 18 Jan 2012 11:50:07 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[7php.com: PHP Interview With Enrico Zimuel Senior Software Engineer At Zend Technologies]]></title>
      <guid>http://www.phpdeveloper.org/news/17399</guid>
      <link>http://www.phpdeveloper.org/news/17399</link>
      <description><![CDATA[<p>
On 7php.com there's a new interview posted <a href="http://7php.com/interview-enrico-zimuel-senior-software-engineer-zend-technologies-everything-is-an-array-in-php/">with Enrico Zimual</a> of <a href="http://zend.com">Zend</a> - "Everything is an Array in PHP".
</p>
<blockquote>
In this edition, I talked with Enrico Zimuel a computer geek since he was 9yrs old. He has written a couple of books namely "Secrets, Spies and Cipher Codes" published by Apogeo in 1999 and the recent "How to use the digital sign" published by Tecniche Nuove in 2010. Enrico has a pretty impressive 'geek' path. He also speaks at many international conferences [...]. You can find his <a href="http://www.slideshare.net/e.zimuel">presentations on slideshare</a>.
</blockquote>
<p>Questions in the interview include:</p>
<ul>
<li>How do you find PHP now as compared to when you first started?
<li>Based on your experience, what are the good and bad parts of PHP?
<li>To someone who wants to become a better PHP developer, what is your advice?
<li>What are some good PHP blog or resources you highly recommend?
</ul>
<p>
Read the <a href="http://7php.com/interview-enrico-zimuel-senior-software-engineer-zend-technologies-everything-is-an-array-in-php/">full interview here</a>.
</p>]]></description>
      <pubDate>Mon, 16 Jan 2012 11:30:04 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Fabien Potencier's Blog: Create your own framework... on top of the Symfony2 Components (part 6)]]></title>
      <guid>http://www.phpdeveloper.org/news/17391</guid>
      <link>http://www.phpdeveloper.org/news/17391</link>
      <description><![CDATA[<p>
In the <a href="http://fabien.potencier.org/article/55/create-your-own-framework-on-top-of-the-symfony2-components-part-6">sixth part of his series</a> on creating a custom framework on top of the Symfony2 components, <i>Fabien Potencier</i> looks at how to improve the previous examples by swapping out the more procedural controllers with actual classes.
</p>
<blockquote>
The move is pretty straightforward and makes a lot of sense as soon as you create more pages but you might have noticed a non-desirable side-effect... The LeapYearController class is always instantiated, even if the requested URL does not match the leap_year route. This is bad for one main reason: performance wise, all controllers for all routes must now be instantiated for every request. It would be better if controllers were lazy-loaded so that only the controller associated with the matched route is instantiated.
</blockquote>
<p>
To help solve the issue, he uses the HttpKernel component and its "controller resolver" to figure out how to call the controller and pass it the correct parameters, but only when needed. A resolver object is created and that is used to instantiate the controller object. Sample "action" calls are included to fill out the basic controller (his "leap year" example) and the full resulting code is included both for the framework and the new object oriented controller.
</p>]]></description>
      <pubDate>Fri, 13 Jan 2012 11:08:12 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[PHPMaster.com: Zend Job Queue]]></title>
      <guid>http://www.phpdeveloper.org/news/17388</guid>
      <link>http://www.phpdeveloper.org/news/17388</link>
      <description><![CDATA[<p>
In <a href="http://phpmaster.com/zend-queue/">this most recent post</a> to PHPMaster.com <i>Alex Stetsenko</i> takes a look at the Zend Job Queue functionality, a part of the <a href="http://www.zend.com/products/server/">Zend Server</a> installation. He talks about some basic usage to make HTTP requests and a more extended example showing report generation.
</p>
<blockquote>
Web applications usually follow a synchronous communication model. However, non-interactive and long-running tasks (such as report generation) are better suited for asynchronous execution. One way to off-load tasks to run at a later time, or even on a different server, is use the Job Queue module available as a part of Zend Server 5 (though not as part of the Community Edition). Job Queue allows job scheduling based on time, priority, and even dependencies
</blockquote>
<p>
In his two examples, he shows the code involved to create a new Queue object and define a HttpJob in it. The first just calls a "sample.php" script that's exposed as a part of your external-facing site and shows how you can get the current status of the job. The more advanced example shows a call to a "report.php" script with a set of options defining things like "type", "length" and "priority". He also points out some other options that can do similar things like <a href="http://gearman.org/">Gearman</a>, <a href="http://nodejs.org/">NodeJs</a> and <a href="http://www.rabbitmq.com/">RabbitMQ</a>.
</p>]]></description>
      <pubDate>Fri, 13 Jan 2012 08:37:31 -0600</pubDate>
    </item>
  </channel>
</rss>

