Our initialization function. This is called on all page requests to initialize the Core
object. Since it's also used during installation (when the database and/or plugins haven't been
installed), the optional parameter controls whether or not the database object, plugins, sessions and user
should be initialized. Different call contexts require different initialization.
public static init ( string $runtimeContext = "ui" ) | ||
$runtimeContext | string | This determines the context in which the Core is being initialized. This
info is used to let plugins instantiate themselves differently, as well as prevent the loading
of incomplete parts of the script. installation: a fresh installation, DB not installed yet installationDatabaseReady: during installation after the DB has been installed ui: (default) for the main generator page generation: when we're in the process of creating actual data resetPlugins: initialized everything except the plugins, which may be safely reset |