<?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>Sun, 12 Feb 2012 21:56:29 -0600</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Michael Nitschinger's Blog: Understanding the Lithium Router - Part 2]]></title>
      <guid>http://www.phpdeveloper.org/news/15961</guid>
      <link>http://www.phpdeveloper.org/news/15961</link>
      <description><![CDATA[<p>
In his latest post <i>Michael Nitschinger</i> extends his <a href="http://phpdeveloper.org/news/15868">first look</a> at the Lithium framework's routing system with <a href="http://nitschinger.at/Understanding-the-Lithium-Router-Part-2">part two</a> of his series - creating some unit and integration tests to help you understand how the various parts work.
</p>
<blockquote>
Routes play an essential role in your request/response-cycle and therefore should also be tested like any other component that you develop. As the Lithium routing infrastructure also consists of classes and methods, we can run unit and integration tests against them.
</blockquote>
<p>
Some of the tests include checking for basic request to controller mapping, testing with an ID in the request, using the export() method and testing various routing to ensure that the output is correct (the integration tests).
</p>]]></description>
      <pubDate>Fri, 25 Feb 2011 08:40:41 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Michael Nitschinger's Blog: Understanding the Lithium Router - Part 1]]></title>
      <guid>http://www.phpdeveloper.org/news/15868</guid>
      <link>http://www.phpdeveloper.org/news/15868</link>
      <description><![CDATA[<p>
<i>Michael Nitschinger</i> has posted the first part of a series about the <a href="http://nitschinger.at/Understanding-the-Lithium-Router-Part-1">internals of the Lithium routing system</a> in the <a href="http://lithify.me">Lithium</a> PHP 5.3 framework.
</p>
<blockquote>
In this article series we'll take an in-depth look at the Lithium router. This first part bootstraps your knowledge and lays a foundation for more advanced topics.
</blockquote>
<p>
He introduces the Router component as having two purposes - matching a URL against the code to handle the request and the other is the reverse, creating URLs out of routes. He links to <a href="http://lithify.me/docs/lithium/net/http/Router">two</a> <a href="http://lithify.me/docs/lithium/net/http/Route">pages</a> where you can find more details on its API. He moves on to the request and response cycle the Router goes through each time a page is requested and walks you through some code to help it all make sense. There's also a bit at the end about creating URLs with the reverse routing methods.
</p>]]></description>
      <pubDate>Mon, 07 Feb 2011 13:55:11 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Federico Cargnelutti's Blog: An Alternative to Zend_Controller: The Router]]></title>
      <guid>http://www.phpdeveloper.org/news/12310</guid>
      <link>http://www.phpdeveloper.org/news/12310</link>
      <description><![CDATA[<p>
<i>Federico</i> has continued his look at his alternative to the Zend_Controller component of the <a href="http://framework.zend.com">Zend Framework</a> - Zf_Controller in <a href="http://blog.fedecarg.com/2009/04/08/an-alternative-to-zend_controller-the-router/">this new part of the series</a> focusing on routing.
</p>
<blockquote>
Here's the good news: Zf_Controller doesn't have a Router. It uses a very simple mapping to determine the name of the controller and action.
</blockquote>
<p>
He gives an example of the "non-routing" and how to work with the input variables for the controller instance - defining default values and setting requirements for them (as defined by matching a regular expression).
</p>
<p>
You can read more about the first part of the series <a href="http://www.phpdeveloper.org/news/12303">here</a>.
</p>]]></description>
      <pubDate>Thu, 09 Apr 2009 08:44:44 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Eran Galperin's Blog: Passing arrays to Zend_Controller_Router]]></title>
      <guid>http://www.phpdeveloper.org/news/10518</guid>
      <link>http://www.phpdeveloper.org/news/10518</link>
      <description><![CDATA[<p>
<i>Eran Galperin</i> has posted <a href="http://www.techfounder.net/2008/06/23/passing-arrays-to-zend_controller_router/">a few hacks</a> you can use for the Zend Framework's Router system to make passing arrays easy and integrated.
</p>
<blockquote>
A big advantage to using the front controller in the Zend Framework is the ability to create nicely formatted urls. [...] The implementation of the default router in the Zend Framework (<a href="http://framework.zend.com/manual/en/zend.controller.router.html">Zend_Controller_Router_Rewrite</a>) does not allow for passing arrays in this manner though, since previously set keys get overwritten if they are declared more than once. This is somewhere between semi-annoying to very annoying, so lets get straight to hacking it into submission. 
</blockquote>
<p>
His <a href="http://www.techfounder.net/2008/06/23/passing-arrays-to-zend_controller_router/">patch</a> only changes one line in the Zend_Controller_Router_Route_Module component - changing it from assigning to a conditional checking for the existence of an array and setting it appropriately.
</p>]]></description>
      <pubDate>Tue, 01 Jul 2008 09:31:52 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Rob Allen's Blog: Zend Framework URLs without mod_rewrite]]></title>
      <guid>http://www.phpdeveloper.org/news/10341</guid>
      <link>http://www.phpdeveloper.org/news/10341</link>
      <description><![CDATA[<p>
<i>Rob Allen</i> has posted a <a href="http://akrabat.com/2008/06/03/zend-framework-urls-without-mod_rewrite/">new entry</a> on getting a Zend Framework application to run correctly even though mod_rewrite (or ISAPI_Rewrite) isn't up and running.
</p>
<blockquote>
Some of our Zend Framework applications have to run on IIS without ISAPI_Rewrite installed. In these cases we need urls of the form http://www.example.com/index.php?module=mod&controller=con&action=act. I couldn't get this to work out of the box with Zend Framework 1.5, so wrote my own router called App_Controller_Router_Route_RequestVars.
</blockquote>
<p>
Most of the post is the code for the router (ready for you to cut and paste) but he's also included a usage example of it so you can easily update your bootstrap file to use it.
</p>]]></description>
      <pubDate>Wed, 04 Jun 2008 12:50:16 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Rob Allen's Blog: Modules (Zend Framework)]]></title>
      <guid>http://www.phpdeveloper.org/news/7220</guid>
      <link>http://www.phpdeveloper.org/news/7220</link>
      <description><![CDATA[<p>
In <a href="http://akrabat.com/2007/02/03/modules/">a new post</a> to his blog, <i>Rob Allen</i> takes a look a a package inside of the Zend Framework - one that allows for much more flexibility with the way your site flows.
</p>
<blockquote>
One of the new features to hit the Zend Framework since 0.7 is Zend_Controller_ModuleRouter and its sibling Zend_Controller_ModuleRewriteRouter. This allows for separating out sets of controlers, models and views into their own modules.
</blockquote>
<p>
He gives both a directory structure and PHP code example of it in action, both in how it normally functions (looks for a controller with the same name as the request) and an example of how he thinks it should work - complete with code and a directory structure to compare to the previous example.
</p>]]></description>
      <pubDate>Mon, 05 Feb 2007 10:33:00 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Matthew Weir O'Phinney's Blog: MVC changes in Zend Framework]]></title>
      <guid>http://www.phpdeveloper.org/news/6850</guid>
      <link>http://www.phpdeveloper.org/news/6850</link>
      <description><![CDATA[<p>
In <a href="http://weierophinney.net/matthew/archives/129-MVC-changes-in-Zend-Framework.html">a new note</a> today, <i>Matthew Weir O'Phinney</i> shares some of his experience as being asked to head up the MVC team for the <a href="http://framework.zend.com">Zend Framework</a>, including some of the changes that have been made.
</p>
<blockquote>
The experience has been incredibly rewarding, however, and I've had the chance to pick the brains of and work with some top-notch developers in the process. In the next week or so, we'll be releasing version 0.6.0 of the framework, and it will include much of my work in the MVC components as part of the core distribution.
</blockquote>
<p>
Some of the changes <a href="http://weierophinney.net/matthew/archives/129-MVC-changes-in-Zend-Framework.html">he lists</a> include:
<ul>
<li>changes that promote greater flexibility and testing
<li>controller classes are now unit tested
<li>the introduction of the request and response objects
<li>a router is no longer needed
<li>the ability to push parameters into the front controller
</ul>
He also gets into a bit of detail on the Response object - what it is, how it works, and how you can set up your own custom versions of it. Check out <a href="http://weierophinney.net/matthew/archives/129-MVC-changes-in-Zend-Framework.html">the full post</a> for more information.
</p>]]></description>
      <pubDate>Fri, 08 Dec 2006 07:11:10 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Ligaya Turmelle's Blog: Quick snip (or Zend Framework in a Subdirectory)]]></title>
      <guid>http://www.phpdeveloper.org/news/6835</guid>
      <link>http://www.phpdeveloper.org/news/6835</link>
      <description><![CDATA[<p>
As <i>Ligaya Turmelle</i> discovered when trying to work with the <a href="http://framework.zend.com">Zend Framework</a> in a subdirectory, it doesn't want to play nice. After poking around a bit, though, she discovered a solution in the Zend_Controller_RewriteRoute package.
</p>
<blockquote>
I am using a subfolder of web root to play with the ZF and was having troubles getting my controller to go to the correct place. After considering hacking both the Apache doc root and the actual Zend_Controller_Router code and writing a patch, I stumbled on the answer - Zend_Controller_RewriteRouter.
</blockquote>
<p>
She <a href="http://www.khankennels.com/blog/index.php/archives/2006/12/06/quick-snip/">includes the quick code</a> that acts as a patch for the framework, letting it know that the directory it should be rewriting to isn't the root of the domain.
</p>]]></description>
      <pubDate>Wed, 06 Dec 2006 09:44:00 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Alexander Netkachev's Blog: Using Zend_Controller in subfolder]]></title>
      <guid>http://www.phpdeveloper.org/news/6368</guid>
      <link>http://www.phpdeveloper.org/news/6368</link>
      <description><![CDATA[<p>
One of the most asked questions when it comes to using the Zend Framework is "how can I use it in a subfolder?" Everything behaves well when it's at the document root of the server it's on, but strange things start happening when it's anywhere below that. There's been server people that have posted solutions, and another can be added to them - <a href="http://www.alexatnet.com/Blog/Index/2006-09-26/using-zend_controller-in-subfolder">this new post</a> from <i>Alexander Netkachev</i>.
</p>
<blockquote>
<p>
This question I had heard many times and now I have a few minutes to write down the answer so that everybody who stuck in the similar trouble could quickly resolve the issue. Who works with Zend Framework, most likely, have read the "Zend_Controller / Getting Started" Zend Framework manual article, which explains how to use Zend_Controller in the root folder of the web server. But it does not answer on the "How to run my Zend Framework application in a subfolder of the web server document folder?" question and I propose you my solutions. 
</p>
<p>
First is rather a hack then a recommended solution, but with it you can start the applications and examples that use standard router. The second is neater but it depends on the Zend_Controller_RewriteRouter class.
</p>
</blockquote>
<p>
The first method makes some changes to the default routing code itself (the hack) to make it no longer just use the REQUEST_URI, but to look at more of the URL to see if subdirectories exist. OF course, the more preferred way to go, and just as simple of an option, is <a href="http://www.alexatnet.com/Blog/Index/2006-09-26/using-zend_controller-in-subfolder">using the framework itself</a> to change the RewriteRouter options to allow for the subdirectory.
</p>]]></description>
      <pubDate>Wed, 27 Sep 2006 07:33:00 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Dmytro Shteflyuk's Blog: Zend Framework - Router for subdirectory-based site]]></title>
      <guid>http://www.phpdeveloper.org/news/4954</guid>
      <link>http://www.phpdeveloper.org/news/4954</link>
      <description><![CDATA[<i>Dmytro Shteflyuk</i> has posted <a href="http://kpumuk.info/php/zend-framework-router-for-subdirectory-based-site/">some his his experiences</a> with the Zend Framework already, specifically in dealing with subdirectory issues.
<p>
<quote>
<i>
I started discovering of Zend Framework and was confronted with a problem. When I've placed my test sample into site's subdirectory (http://localhost/test/), default router tried to find TestController which is not exists of course and routed me to IndexController/noRoute. It's not good for me. I decided to create my own router.
</i>
</quote>
<p>
He <a href="http://kpumuk.info/php/zend-framework-router-for-subdirectory-based-site/">gives the code</a> he created to make the routing system work, using the Zend_Controller_Router_Interface and Zend_Controller_Front packages to handle the incoming requests.
]]></description>
      <pubDate>Wed, 08 Mar 2006 07:36:39 -0600</pubDate>
    </item>
  </channel>
</rss>

