The basic unit of content is an Objekt. Many subclasses of this can be created to handle different content types (Article, Rental, Cartoon, Blog Entry, Soundfile etc.)

Each Objekt class specifies the fields that its data requires, such as title, summary, picture. The fields are defined using the various InputObjects. These are also involved with the inserting, updating and selecting of data out of the database. An InsertObject or UpdateObject is passed to each InputObject, and it parse the POST and inserts/updates or throws an error.

Each Objekt subclass can implement a display() and a summarize() method to customize how it should display itself. The display/summarize html itself is done using templates.

If an Objekt subclass doesn't implement display/summarize, you will get the generic display/summarize. This is often sufficient for boring objects.

There are also templates for editing, for inserting and for showing the user errors for correction. In most cases it is the same smart generic template Objekt-edit.tpl

Editing/Inserting/Deleting/Viewing of the Objekts is done on a series of pages that handles all the permission checks, error handling and logging needed. edit.php new.php delete.php view.php etc. These pages are in the shared-www directory. URL rewriting is used to map pretty urls to these pages.

Multiple sites

The system is set up to support multiple sites sharing the same code base. It is possible to run each site on its own database, to share a database but keep the tables separate (using CX_DB_PREFIX) or to combine sites into shared database tables. Each site has a SITE_KEY by which it identifies its content and its users. It is easily possible to share data/content between sites when that is appropriate for the business application.

There is a library of generic useful classes in MAIN_CLASS_DIR/objekts. Each site can have its own specific classes. Sites can also share a network folder such as MNOV_CLASS_DIR.

Classes, class conf files, templates, hooks, and handlers can be overriden and reimplemented in the subsequent CLASS_DIRS folders. This allows customization for behavior or design. By principal, its best to first try and use the CSS to affect any changes.

The play by play

Every page starts by including the Application.php file from that website's DOCUMENT_ROOT. This is the site configuration file: such as SITE_KEY, what and where the CLASS_DIRS are, what the URL and name of the site is and where the uploads directory is.

An Application file determines what site is actually running. Most of the settings of the site itself are then found in the database, looked up with the SITE_KEY.

It is possible to run more than one installation in a single domain (such as the one you are reading this in now massmind.com/admin ) by detecting which installation you want in the Application.php file and forking to one or another Application files.

This then includes the globalApplication which declares the main frequently used functions.