--------------------------------------------------------------------- Strangecode codebase 2.1 --------------------------------------------------------------------- css/utilities.inc.php and css/codebase.inc.php now have sc- prepended to all selectors. This regex will convert an existing site to the new sc- format: s/class="([\w-]+ )*(tiny|small|medium|large|full|twolines|short|tall|fullscreen|nowrap|clearboth|center|right|padright|padleft|padleft|help|monospaced|pkg)( [\w-]+)*"/class="$1sc-$2$3"/gi --------------------------------------------------------------------- Strangecode codebase 2.0 --------------------------------------------------------------------- Codebase self contained. runs without reference to external files or info. - can be located in /usr/local/php/lib/php for server-wide access - does not include any files outside codebase - does not write to files outside codebase - does not try to determine it's location or site parameters. this will minimize it's failure to glean this info. - will still run if info missing: db creds, log dir, session info. - can be located in /usr/local/lib/php if necessary, so accessible by all sites. remove interdependencies: - App() is the primary dependency for other classes. It includes Utilities.inc.php silently. - Updated classes requiring external files, such as html templates and email templates, classes now self-contained. Things with modified interfaces: - App - Auth_SQL - DB - DBSessionHandler - Lock - Version - Cache - Upload One application will always have distinct: - Configurations: - log dir - log config - debugging - charset - session data - Objects: - auth - db - Environment: - seperate codebase installs if necessary for each app - unique include path - site/doc/web root - lang - $dbh database handler App object: - object belongs to a realm, keeping messages and session data within specific site/app. - uses the singleton pattern so only one instance of App exists for each app. - app object can be accessed globally without reference to object name by calling methods statically, e.g. App:logMsg() - seperate application and codebase parameters from site configuration variables. Use $app->getParam('var') or $app->getParam('var') to get app params. F or site configurations do whatever you want (I'm using $cfg['node']['features'] format for configurations) App configuration parameters - defaults part of the app class - do not need to be set in any specific order - missing vars are dynamically accounted for. Auth_SQL object: - Modified to set the auth-type within the object. We needed to use one object name ($auth) for all instances so we can use template that use this variable name commonly. login.php, lock.php, versions.php, password.php -- all in the codebase services will be used globally on multiple sites and need this variable name set. DB object: - Self contained class for DB functions. $db->query is the only necessary function. Maintains connections and state independent of App. Full test suite for all codebase libraries. Run from the command line: "codebase/tests/run_tests.sh;" Classes that access database tables have a function initDB() that will setup the basic schema necessary to run. This includes Auth_SQL, Version, Lock, and DBSessionHandler. And much much more still to document... --------------------------------------------------------------------- Strangecode codebase 1.0.0 release --------------------------------------------------------------------- This is the primary stable release used before we started using Subversion. It was maintained erratically by one erratic person. No revision info documented, sorry.