ZF-7161: Class does not load with Zend framework 1.8.4

Issue Type: Bug Created: 2009-06-30T02:15:10.000+0000 Last Updated: 2009-07-31T21:10:58.000+0000 Status: Resolved Fix version(s): - 1.8.4 (23/Jun/09)

Reporter: Gaurav Priyadarshi (gauravp) Assignee: Stanislav Malyshev (stas) Tags: - Zend_Amf

Related issues: Attachments: - amf_config.ini


We use the following gateway to handle the amf requests:

<pre class="highlight">
ini_set("display_errors", 1);
$dir = dirname(__FILE__);
$webroot = $_SERVER['DOCUMENT_ROOT'];
$configfile = "$dir/amf_config.ini";

//default zend install directory
$zenddir = $webroot. '/ZendFramework/library';

//Load ini file and locate zend directory
if(file_exists($configfile)) {
        $zenddir = $arr['zend']['zend_path'];

// Setup include path
    //add zend directory to include path
// Initialize Zend Framework loader
require_once 'Zend/Loader/Autoloader.php';
// Load configuration
$default_config = new Zend_Config(array("production" => false), true);
$default_config->merge(new Zend_Config_Ini($configfile, 'zendamf'));
$amf = $default_config->amf;

// Store configuration in the registry
Zend_Registry::set("amf-config", $amf);
// Initialize AMF Server
$server = new Zend_Amf_Server();
if(isset($amf->directories)) {
    $dirs = $amf->directories->toArray();
    foreach($dirs as $dir) {

// Initialize introspector for non-production
if(!$amf->production) {
    $server->setClass('Zend_Amf_Adobe_Introspector', '', array("config" => $default_config, "server" => $server));
    $server->setClass('Zend_Amf_Adobe_DbInspector', '', array("config" => $default_config, "server" => $server));
// Handle request
echo $server->handle();

With Zend framework 1.8.3 this works fine, but with Zend Framework 1.8.4, we receive the following error:

<pre class="highlight">
Server error Class "EmployeeService" does not exist 
#0 C:\wamp\www\ZendFramework\library\Zend\Amf\Server.php(540): Zend_Amf_Server->_dispatch('count', Array, 'EmployeeService') 
#1 C:\wamp\www\ZendFramework\library\Zend\Amf\Server.php(616): Zend_Amf_Server->_handle(Object(Zend_Amf_Request_Http)) 
#2 C:\wamp\www\TestZend184-debug\gateway.php(49): Zend_Amf_Server->handle() 
#3 {main} 


Posted by Stanislav Malyshev (stas) on 2009-06-30T09:49:41.000+0000

Please attach config file and describe where EmployeeService class is.

Posted by Gaurav Priyadarshi (gauravp) on 2009-06-30T11:13:25.000+0000

the amf_config.ini file

Posted by Gaurav Priyadarshi (gauravp) on 2009-06-30T11:15:37.000+0000

Find the attached files. amf_config_ini file resides in the same dir as the gateway file. EmployeeService.php resides under services folder under this directory.

Posted by Stanislav Malyshev (stas) on 2009-06-30T16:56:36.000+0000

I think I know what the problem is. For some reason in 1.8.4 package there's an old version of Zend/Loader/PluginLoader.php. Take the new one here:…

It should work with it.

Posted by Satoru Yoshida (satoruyoshida) on 2009-07-31T21:10:51.000+0000

It seems to be solved at 1.8.4PL

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.