Issue Type: Docs: Improvement Created: 2012-08-16T22:19:05.000+0000 Last Updated: 2012-08-17T09:17:08.000+0000 Status: Open Fix version(s): Reporter: Michal Novotny (clime) Assignee: Matthew Weier O'Phinney (matthew) Tags: - autoloader
Related issues: Attachments:
i think the documentations for The Autoloader and Resource Autoloaders should be improved. I have had no idea how autoloading works before I started to work with Zend. Still, when I started to read the autoloding docs, I expected to grasp the concept easily. Actually, it took me lots of time and I needed to read some other resources and try lots of things myself. The way autoloading works in Zend was totally counterintuitive to me even after going through the manual several times.
I think the missing thing in the docs is: "how it actually works". For Zend_Loader_Autoloader I would like to see there the following information: - if I introduce a class name with a registered prefix, the autoloader searches for it in php include paths - for the class to be found its name must match (after substitution of / for _) the relative path from the include path under which it resides (+ example to clear this out)
For Resource Autoloaders I would mention that it has no relation to php include paths (afaik) and that its functionality stands and falls on the added resource types. I would except a thing like: $resourceLoader = new Zend_Loader_Autoloader_Resource(array( 'basePath' => WEBSITE_PATH, 'namespace => 'Website'));
without any added resource types to do something like adding WEBSITE_PATH to include paths and registering namespace Website so that I can do new Website_Model_Foo immediately. Well it does not work like that and it would be nice to clear that out in the docs.
Thank you for the great project.
Posted by Frank Brückner (frosch) on 2012-08-17T09:16:57.000+0000
Version 2 is around the corner and I think there will be no further major improvements for the ZF1 docs.
Have you found an issue?
See the Overview section for more details.