<?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 11:31:30 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[PHPMaster.com: REST - Can You do More than Spell It? Part 4]]></title>
      <guid>http://www.phpdeveloper.org/news/17981</guid>
      <link>http://www.phpdeveloper.org/news/17981</link>
      <description><![CDATA[<p>
PHPMaster.com has posted the latest tutorial in their series covering RESTful APIS - <a href="http://phpmaster.com/rest-can-you-do-more-than-spell-it-4/">part four</a> of "REST - Can you do More than Spell it?" In this latest part of the series, they focus on something very key to RESTful services, the HTTP spec (and headers).
</p>
<blockquote>
We're getting close to the end now, and the only thing remaining is to discuss a little more about the protocol you'll most likely use in any RESTful application that you write. Because HTTP is so often used with REST, that's the protocol I'd like to focus on.
</blockquote>
<p>
He goes through the structure of a typical (raw) HTTP header and talks about some of the more common headers and what actions/settings they represent. He includes examples of setting headers (with <a href="http://php.net/header">header</a>, naturally) and a <a href="http://php.net/curl">curl</a> example showing how to set the request headers. The tutorial is finished off with a brief mention of custom HTTP headers and the the good and bad that comes with them.
</p>]]></description>
      <pubDate>Mon, 21 May 2012 08:44:26 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[PHPMaster.com: REST - Can You do More than Spell It? Part 3]]></title>
      <guid>http://www.phpdeveloper.org/news/17952</guid>
      <link>http://www.phpdeveloper.org/news/17952</link>
      <description><![CDATA[<p>
On PHPMaster.com they've posted <a href="http://phpmaster.com/rest-can-you-do-more-than-spell-it-3/">the third part</a> of their series looking at development around RESTful APIs. In this latest article they take an outsider's perspective and look at using services rather than creating one from scratch. (<a href="http://phpdeveloper.org/news/17881">Part 1</a>, <a href="http://phpdeveloper.org/news/17912">Part 2</a>)
</p>
<blockquote>
Imagine it's a warm, sunny, summer day. You're just walking along, taking a leisurely noonday stroll, when all of a sudden you come face to face with a RESTful API. What do you do? How do you interface with it? Or, as those of us in the know would say, "how do you consume RESTful services?" That, my friends, is the subject of this article.
</blockquote>
<p>
They mention using other tools (like components/features of common frameworks) to interface with the services, but end up using the <a href="http://php.net/curl">curl</a> extension to make  a POST request to a service to add a few events to a "/summerschedule" resource.
</p>]]></description>
      <pubDate>Mon, 14 May 2012 09:41:33 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Seth May's Blog: The 5 Ws of Data Validation - Part 1]]></title>
      <guid>http://www.phpdeveloper.org/news/17871</guid>
      <link>http://www.phpdeveloper.org/news/17871</link>
      <description><![CDATA[<p>
With a reminder about the best practice of always validating your data, <i>Seth May</i> has <a href="http://blog.sethmay.net/2012/04/the-5-ws-of-data-validation/">this new post</a> about the "Five Ws" of validation - why, when, where and who.
</p>
<blockquote>
As web developers, the applications you write are complex data processing engines.  They try and convince your users to enter good, meaningful data and to respond in solid, predictable ways based on what was entered. Robust data validation will allow the rest of you application to work effectively. [...] Data is scrutinized in various ways to make sure that it adheres to basic restrictions and to fundamental properties.  It's no good receiving a sandwich when you expect a car.
</blockquote>
<p>The questions he answers are:</p>
<ul>
<li>Why is Data Validation Important?
<li>Where Should I be Validating Data?
<li>When Should My Data Be Validated?
<li>Who is Responsible for Validation?
<li>How Do I Validate My Data? (yes, there's a "w" in there!)
</ul>
<blockquote>
In the real world data is ugly, crazy, and untrustworthy. Your only hope to taming the data beast is to diligently, methodically validate your data.
</blockquote>]]></description>
      <pubDate>Thu, 26 Apr 2012 11:14:03 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[PHPMaster.com: An Intro to Virtual Proxies, Part 2]]></title>
      <guid>http://www.phpdeveloper.org/news/17869</guid>
      <link>http://www.phpdeveloper.org/news/17869</link>
      <description><![CDATA[<p>
Following up on his <a href="http://phpdeveloper.org/news/17838">previous article</a>, <i>Alejandro Gervasio</i> has a new post to PHPMaster.com with the <a href="http://phpmaster.com/intro-to-virtual-proxies-2/">second part of his series</a> on using virtual proxies in PHP.
</p>
<blockquote>
Resting on the foundation of Polymorphism (dynamic Polymorphism, not the ad-hoc one often achieved through plain method overriding), Virtual Proxies are a simple yet solid concept which allows you to defer the construction/loading of expensive object graphs without having to modify client code.
</blockquote>
<p>
He shows how to create a collection of domain objects that use proxies to populate their data. He includes the code for creating a "Post" interface/object as well as a Comment interface/object. These are put into a "CommentCollection" and, when it's accessed, pull the item in the collection out, only populating the data on demand.
</p>]]></description>
      <pubDate>Thu, 26 Apr 2012 09:24:23 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Juan Treminio's Blog: Getting Started with Kohana 3 (series)]]></title>
      <guid>http://www.phpdeveloper.org/news/17801</guid>
      <link>http://www.phpdeveloper.org/news/17801</link>
      <description><![CDATA[<p>
<i>Juan Treminio</i> has started up series of posts over on his blog looking at the Kohana framework and guiding you through the creation of a sample application with it (in-depth). 
</p>
<blockquote>
The Kohana Framework started off as a fork of the very popular CodeIgniter Framework. During the KO 2.x versions, it stayed fairly similar to how CodeIgniter functioned, and a developer could easily jump from one to the other and feel very familiar. With the introduction of the Kohana 3.x version, this all changed, as Kohana was completely rewritten from the ground up. Now, unless you're a seasoned PHP developer, you may have difficulty making the jump from other frameworks in Kohana. I have written this tutorial to be your step-by-step guide into the world of Kohana
</blockquote>
<p>So far, he's posted three parts of the series:</p>
<ul>
<li><a href="http://jtreminio.com/2012/03/getting-started-with-kohana-3-part-i/">Initial setup and configuration</a>
<li><a href="http://jtreminio.com/2012/03/getting-started-with-kohana-3-part-ii/">Bootstrapping the application</a>
<li><a href="http://jtreminio.com/2012/04/getting-started-with-kohana-3-part-iii-controller-mvvm-kostache/">Controller/MVVM/KOstache</a>
</ul>
<p>
Keep an eye on <a href="http://jtreminio.com/">his blog</a> for more posts in this great series!
</p>]]></description>
      <pubDate>Wed, 11 Apr 2012 08:19:15 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Satish Gopal's Blog: Building RESTful services - part 2]]></title>
      <guid>http://www.phpdeveloper.org/news/17744</guid>
      <link>http://www.phpdeveloper.org/news/17744</link>
      <description><![CDATA[<p>
In <a href="http://satishgopal.wordpress.com/2012/03/26/building-restful-services-part-2/">part two</a> of his series (<a href="http://satishgopal.wordpress.com/2011/11/01/building-restful-services-part-1/">part one is here</a>) on building RESTful interfaces, <i>Satish Gopal</i> talks about things like hypermedia and HATEOAS.
</p>
<blockquote>
This is part 2 of "Building RESTful services".  In <a href="http://satishgopal.wordpress.com/2011/11/01/building-restful-services-part-1/">Part 1</a> we talked about Level 1 and Level 2 of the Richardson Maturity Model. [...] Now imagine if you had to [find the URI] for every single website, each having a different kind of document in a different custom format. The internet would certainly not be what it is today. Yet a majority of the APIs built today make us do this. This is where the hypermedia concept comes in.
</blockquote>
<p>
He describes the concepts behind hypermedia, giving examples of how this sort of data can be included in your API's responses. To illustrate, he includes some "link" information that then points to other data for things like "moreInfo" and "reviews" in his Book example. He also describes HATEOAS (Hypermedia As The Engine Of Application State) showing how to use this "link" information to make it simpler for the end user/application to navigate around between data sources in the application.
</p>]]></description>
      <pubDate>Wed, 28 Mar 2012 11:43:49 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Daniel Krook's Blog: Migrating PHP applications to DB2]]></title>
      <guid>http://www.phpdeveloper.org/news/17650</guid>
      <link>http://www.phpdeveloper.org/news/17650</link>
      <description><![CDATA[<p>
As <i>Daniel Krook</i> mentions in <a href="http://krook.net/archives/827">his latest blog post</a>, the IBM developerWorks site has just posted the last part of a series he's been writing about migrating a PHP application's backend over to DB2.
</p>
<blockquote>
IBM developerWorks has just published the final part in our series on migrating a PHP application from MySQL to DB2. [...] In addition to sharing our own experience, the series highlights the number of resources available to you to carry out your own migration.
</blockquote>
<p>The series is broken up into four parts:</p>
<ul>
<li><a href="http://www.ibm.com/developerworks/data/library/techarticle/dm-1011phpdb2mysql/">Prepare for your migration</a>
<li><a href="http://www.ibm.com/developerworks/data/library/techarticle/dm-1103phpdb2mysql2/">Migrate your data</a>
<li><a href="http://www.ibm.com/developerworks/data/library/techarticle/dm-1108phpdb2mysql3/">Convert your PHP code</a>
<li><a href="http://www.ibm.com/developerworks/data/library/techarticle/dm-1203phpdb2mysql4/">Deploy your application</a>
</ul>]]></description>
      <pubDate>Fri, 09 Mar 2012 08:20:28 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[PHPMaster.com: Creating Web Services with PHP and SOAP, Part 1]]></title>
      <guid>http://www.phpdeveloper.org/news/17565</guid>
      <link>http://www.phpdeveloper.org/news/17565</link>
      <description><![CDATA[<p>
On PHPMaster.com today there's a new tutorial posted, the first part in a series, showing how to <a href="http://phpmaster.com/web-services-with-php-and-soap-1/">create SOAP web services</a> with the help of the <a href="http://sourceforge.net/projects/nusoap/">NuSOAP</a> library.
</p>
<blockquote>
In this first of a two part series on web services I'll talk about the SOAP specification and what is involved in creating SOAP messages. I'll also demonstrate how to create a SOAP server and client using the excellent NuSOAP library to illustrate the flow of SOAP. In the second part I'll talk about the importance of WSDL files, how you can easily generate them with NuSOAP as well, and how a client may use a WSDL file to better understand your web service.
</blockquote>
<p>
He introduces you to the concepts behind SOAP, the normal structure of a SOAP-formatted XML message and what an example might look like for fetching a stock price from a remote service. He then shows how to use <a href="http://sourceforge.net/projects/nusoap/">NuSOAP</a> to create both a simple server and client to pull information about books - sample code and <a href="http://cdn.phpmaster.com/files/2012/02/soap-1-01.jpg">a screenshot</a> of the output is included.
</p>]]></description>
      <pubDate>Tue, 21 Feb 2012 09:52:20 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Fabien Potencier's Blog: Create your own framework... on top of the Symfony2 Components (part 12)]]></title>
      <guid>http://www.phpdeveloper.org/news/17445</guid>
      <link>http://www.phpdeveloper.org/news/17445</link>
      <description><![CDATA[<p>
In <a href="http://fabien.potencier.org/article/62/create-your-own-framework-on-top-of-the-symfony2-components-part-12">this final post</a> of his series about building a framework on Symfony2 components, <i>Fabien Potencier</i> focuses again on flexibility - allowing you to have more than one front controller with different configurations thanks to dependency injections.
</p>
<blockquote>
Does it means that we have to make a choice between flexibility, customization, ease of testing and not having to copy and paste the same code into each application front controller? As you might expect, there is a solution. We can solve all these issues and some more by using the Symfony2 dependency injection container.
</blockquote>
<p>
The Symfony2 DIC (DependencyInjection) allows you to create a container with the objects and settings that you want and inject that into the main "Framework" class for its use. He registers most of the components he's added over the series like the UrlMatcher, RouterListener, ExceptionListener, EventDispatcher and the Framework class itself. This is all stored in a separate file(s) and can be conditionally included based on your environment. He shows how to register a custom listener, add parameters to the DIC configuration.
</p>]]></description>
      <pubDate>Wed, 25 Jan 2012 08:36:48 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Fabien Potencier's Blog: Create your own framework... on top of the Symfony2 Components (part 11)]]></title>
      <guid>http://www.phpdeveloper.org/news/17440</guid>
      <link>http://www.phpdeveloper.org/news/17440</link>
      <description><![CDATA[<p>
In <a href="http://fabien.potencier.org/article/60/create-your-own-framework-on-top-of-the-symfony2-components-part-11">part eleven</a> of his "Build a Framework on top of Symfony2", <i>Fabien Potencier</i> improves on his earlier versions of the code by adding in the HttpKernel support for handling events and errors that might come up in the application.
</p>
<blockquote>
If you were to use our framework right now, you would probably have to add support for custom error messages. Right now, we have 404 and 500 error support but the responses are hardcoded in the framework itself. Making them customizable is easy enough though: dispatch a new event and listen to it. Doing it right means that the listener has to call a regular controller. But what if the error controller throws an exception? You will end up in an infinite loop. There should be an easier way, right?
</blockquote>
<p>
Using the "RouterListener" functionality, he sets up an "ExceptionListener" and points that to an error handling controller with its own "exceptionAction". This action takes the exception information and displays a "Something went wrong!" message along with the details. He also includes an update to the Response handling to allow for returning a string back from the controller instead of a Response object.
</p>]]></description>
      <pubDate>Tue, 24 Jan 2012 11:04:44 -0600</pubDate>
    </item>
  </channel>
</rss>

