I like the way the discussion is going in the Developer's Lounge. If I may let me throw my 2 cents into this discussion. If you break down the portal into several parts say; Core/Global, Module/Limited Scope, and Add-On/Global.
Features in each:
- Functions necessary in all parts of the website. Variables with global scope.
- User Profile / Preferences
- Whos Online
- Private Messages
- Error Detection and Notices
- Core Language Files (more on this later)
- Core Administration
- User / Groups Administration
- Message Posting Function
- Word Censor
- Functions created for a specific module. Variables have limited scope to just within the module pages.
- Module Specific Language Files
- Module Specific Administration Functions
- Module Rules for handling inherited core variables and data
- Module functions
- Functions which expand the core features. Variables with global scope.
- Add-on Specific Language Files
- Add-on Specific Administration Functions
- Add-on Rules and interface for handling function calls from unknown modules (basically add-ons are black boxes)
As I see it the task for the portal developers is to create a set of rules by which modules and add-ons will be written uniformly. The portal would then be able to either automatically detect (checking a folder for new files with a .mod extension or something) or provide an interface by which the website administrator could pick and choose which add-ons or modules were active.
The next logical step would be to read the .mod file (I was thinking of something similar to the way a Makefile works) and cache the data, store it in a db or read the file each time (I see a major performance hit here). The .mod file would basically be a collection of variables to be initialized, file paths and setup information. A companion to the .mod file would be a .sql file. This file would contain the needed database additions. The .sql file would be processed by the core and internally logged that the changes were made.
This is all theory at this point and I have no code to back it up yet. I just put this out here to help you get your creative juices flowing.