ZF-6318: Feature Request: Zend_Loader to use PHP 5.3 namespaces.

Issue Type: New Feature Created: 2009-04-16T06:22:53.000+0000 Last Updated: 2012-11-20T20:52:31.000+0000 Status: Closed Fix version(s): Reporter: Maik Kreutzfeldt (grayfellow) Assignee: None Tags: - Zend_Loader

Related issues: Attachments:


In a project proposal I use the namespace feature of PHP 5.3 and tried to integrate it with Zend_Loader.

The goal is to reduce:

<pre class="highlight">
class Some_Rather_Long_Name {}

to something like

<pre class="highlight">
namespace Some/Rather/Long;
class Name {}

which works fine, but needs the following patch to Zend_Loader::loadClass()

<pre class="highlight">
        // autodiscover the path from the class name
        $file = str_replace(array('_', '\\'), DIRECTORY_SEPARATOR, $class) . '.php';

It would be great to have this simple addition in the Zend Framework!


Posted by Giorgio Sironi (giorgiosironi) on 2009-07-31T01:42:53.000+0000

This gain importance as php 5.3 is out. A problem also exists in Zend_Loader_PluginLoader as it cannot load namespaced view helpers and similar.

Posted by Rob Allen (rob) on 2012-11-20T20:52:31.000+0000

Bulk change of all issues last updated before 1st January 2010 as "Won't Fix".

Feel free to re-open and provide a patch if you want to fix this issue.

Have you found an issue?

See the Overview section for more details.


© 2006-2018 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.