-- sinkingfish <[EMAIL PROTECTED]> wrote (on Wednesday, 08 October 2008, 02:43 AM -0700): > Im currently in the early stages of setting up a zf based site. I want to > put out a question about where to store different classes. I have object > classes (eg a user class with getters and setters), I have factory classes > for instantiating the object classes and I have database classes for > accessing the database. > > What Im wondering is where to save these files? Do they all belong in the > models folder, or do just the database classes belong there? I also have a > library folder containing the zend framework and my own personal library for > the project. Do the object classes and factorys belong in the library folder > too?
It depends. Are these classes ones that you'll re-use between projects, or are they application-specific? or are they specific to a given application module? Typically, the rule of thumb is that if they are specific to the application or application module, they go in the models directory; if they are something you'll re-use between applications and modules, they would go in your library. -- Matthew Weier O'Phinney Software Architect | [EMAIL PROTECTED] Zend Framework | http://framework.zend.com/
