tags:

views:

15

answers:

1

Hi,

I got problems with my ZF Models.

Where I create new model, put it in Dbtable/Articles.php and name class as Model_DbTable_Articles it is working. But when I name class Articles I got error:

Fatal error: Class 'Articles' not found

Why? :)

A: 

I put this in my bootstrap.php file

$autoloader = $application->getAutoloader();
$resourceLoader = new Zend_Loader_Autoloader_Resource(array(
    'basePath' => APPLICATION_PATH,
    'namespace' => '',
    'resourceTypes' => array(
        'form' => array(
            'path' => '/forms/',
            'namespace' => 'Form_',
        ),
        'model' => array(
            'path' => '/models/',
            'namespace' => 'Model_'
        ),
        'table' => array(
            'path' => '/tables/',
            'namespace' => 'Table_'
        ),
    ),
));
Ballsacian1