Phalcon\Loader::registerPrefixes strange work (confused)

Hello,

I've following code:

$loader = new \Phalcon\Loader();

$loader->registerPrefixes([
    "AuthorizeNet" => $config->vendorClassesDir . "payment/vendor/authorize_net/",
]);

$loader->register();

when I call $x = new \AuthorizeNetAIM(); i recive a fatal error that class AuthorizeNetAIM not found. Hovewer, if i'll update

$loader->registerPrefixes([
    "AuthorizeNe" => $config->vendorClassesDir . "payment/vendor/authorize_net/",
]);

than code $x = new \AuthorizeNetAIM(); will work.

Can anyone explain what's wrong?

Thank you.

PS. tested on Phalcon 1.3.3, 1.3.4

Hi, I want to implement HTMLPurifier to load

$loader->registerPrefixes ([
    'HTMLPurifier'      =>  APP_PATH.'/HTMLPurifier'
]);

but error Fatal error: Call to undefined method Phalcon\Loader::registerPrefixes() in....

Please help me fix



2.9k

Hi, I want to implement HTMLPurifier to load

```php $loader->registerPrefixes ([ 'HTMLPurifier' => APP_PATH.'/HTMLPurifier' ]); ``` but error Fatal error: Call to undefined method Phalcon\Loader::registerPrefixes() in....

Please help me fix

Looks like Phalcon isn't installed or Phalcon's verion is unbelievably old