I've deleted every Zend Framework class in the folder "library/Zend", I used the 1.7 version and wanted to upgrade to 1.12. After the deletion I've uploaded the Zend Framework 1.12 classes in "library/Zend".
I'm facing an issue in loading the classes. In "public/index.php" I used registerAutoload(). This was depricated so I changed it to this:
require_once 'Zend/Loader/Autoloader.php';
$loader = Zend_Loader_Autoloader::getInstance();
Then, for each class I use in the Controller I have to manually add it like this:
$loader->registerNamespace('Paths');
$loader->registerNamespace('Certificate');
$loader->registerNamespace('Zim_Properties');
$loader->registerNamespace('Zim_Controller_Dispatcher');
$loader->registerNamespace('Controller_Plugin_ActionSetup');
$loader->registerNamespace('Controller_Plugin_History');
$loader->registerNamespace('Zim_Model');
$loader->registerNamespace('Zim_Controller_Action');
$loader->registerNamespace('Controller_ProposalInvoice');
$loader->registerNamespace('Stats');
$loader->registerNamespace('Controller_ArticleService');
If I remove this registerNamespace I get an Fatal error: Class 'Controller_ArticleService' not found in /home/juliaxd8/domains/jmediatechnology.eu/public_html/factuurtogo2/application/controllers/ArticleController.php on line 3
Because of the manually registration I could forgot something/make a typo. Can I do auto load classes?
Zim_*classes) and those that reside in the appnamespace (typically,Application_) that need to be handled via a special resource autoloader. - David Weinraub