Hi, Hate to keep bringing up Drupal as a model, but I think they've got a great way of doing this, particularly if the goal is to encourage 3rd party development on top of a core. Two key principles here: group everything necessary for a particular set of functionality together as a module, under a single directory; and provide a built-in override system that allows local changes to take precedence over core. In Drupal, there are some core APIs in an "include/" directory, but much of the core functionality has been abstracted out into modules that can serve as examples for third parties to extend. When loading a module, Drupal has a well-defined search path: 1. sites/<domainname>/modules/ 2. sites/all/modules/ 3. modules/ ... basically with this layout, you can share a bunch of modules in a single code base supporting multiple sites, but if you need to patch a module you simply create a copy and put it in a more specific path. Themes/templates use the same approach, but a path ending in "themes/" instead of "modules/". Drupal does rely on mod_rewrite to rewrite all paths to a single controller/dispatcher, so the filesystem path has little to do with the URL. It also has several layers of caching -- it only looks for new module/path handlers when its cache has been cleared, and then it scans the filesystem looking for possible paths and auto-populates its "menu_router" table based on what it finds. I'm not sure what the demand is for multi-company hosting, but I definitely like having a built-in override system in place so you have an easy way to apply patches to core files -- without actually creating essentially a forked version. And having so many different places to touch functionality that all should go together -- yes, I'd love to see some cleanup. I guess I'd suggest turning AR, AP, GL, etc into modules, and grouping the data objects, scripts, and default UI into a single directory related to that functionality. I also think there should be a way to override the UI elements/templates in a single, company-specific location (similar to Drupal themes) so that it's easy to apply company branding, etc. without editing core files. I know templates are already like this -- I'd like to extend it to the application UI... My thoughts, anyway -- I've worked with dozens of web applications, and Drupal's file layout is head and shoulders above the rest, worthy of emulation. Cheers, John Locke http://freelock.com On 07/03/2011 02:24 PM, Erik Huelsmann wrote: Hi, |