To start with this one: I don't see that. The fact that the example folder structure doesn't show sub folders doesn't mean you should dump everything in one folder. Use your own judgement.Jason Judge wrote on Wednesday 25th of January 2012:Just to add to this, the documentation here http://docs.fuelphp.com/general/packages.html says to just dump all the classes into one folder.
No, there isn't. It largely depends on what the package is supposed to do, whether you include third party classes that require a specific folder structure, etc. Again, use your best judgement.Jason Judge wrote on Wednesday 25th of January 2012:Is there a standard or recommended way to structure classes in packages?
As to classes in sub folders, the autoload supports two methods:Jason Judge wrote on Wednesday 25th of January 2012:For example, if I were to put a model "Foo" into a package, would it be called "Model_Foo" and be placed into packages/mypackage/classes/model/foo.php?
// in both cases assuming packages/mypackage/classes/model/foo.php: // option 1 namespace mypackage; class Model_Foo {} // option 2 namespace mypackage/Model; class Foo {}
It looks like you're new here. If you want to get involved, click one of these buttons!