Posts tagged autoloader
Zend Framework – Add custom resource type to autoloader
113 years ago
This week I wanted to created the folder “application/grids/” to store my grids in. For example the path to the grid is “application/grids/Product.php”. The code inside this PHP file:
class Application_Grid_Product
{
}
You will now get the error “Fatal error: Class ‘Application_Grid_Product’ not found”. The new path must be added to the Zend Autoloader in order to load the required classes. Your bootstrap must look like this:
class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
{
protected function _initLoaderResources()
{