Best Practices

Please note that the core files are in phork/php/core/, and these should never be altered. If any core changes are necessary there are application extensions in phork/php/app/ which can be used.

The following app files are included from the CoreBootstrap:

class_exists('AppConfig', false) || require('php/app/AppConfig.class.php');
class_exists('AppDisplay', false) || require('php/app/AppDisplay.class.php');
class_exists('AppEvent', false) || require('php/app/AppEvent.class.php');
class_exists('AppLanguage', false) || require('php/app/AppLanguage.class.php');
class_exists('AppLoader', false) || require('php/app/AppLoader.class.php');
class_exists('AppRegistry', false) || require('php/app/AppRegistry.class.php');
class_exists('AppUrl', false) || require('php/app/AppUrl.class.php');

Site-Specific App Files

In the event that you need different app files for each site you should manually include the site-specific app files in the front controller before the bootstrap is included. They should be named the same as the app files in the phork/php/app/ directory. This way the class_exists() check in the CoreBootstrap will find them and they won't be included from the default location.

//include the app loader override class
require_once("{$strSiteDir}app/AppLoader.class.php");

//include the bootstrap class
require_once("{$strSiteDir}bootstraps/SiteBootstrap.class.php");