<?php /** * Phire CMS 2.0 Bootstrap File */ // Calculate and define the base path if (!defined('BASE_PATH')) { $basePath = str_replace(array(realpath($_SERVER['DOCUMENT_ROOT']), '\\'), array('', '/'), realpath(__DIR__)); define('BASE_PATH', !empty($basePath) ? $basePath : ''); } // Require the config file require_once 'config.php'; // Check the path and URI constants if (!defined('BASE_PATH') || !defined('APP_PATH') || !defined('APP_URI') || !defined('DB_INTERFACE') || !defined('DB_NAME')) { throw new \Exception('Error: The config file is not properly configured. Please check the config file or install the system.'); } // Require the Pop Autoloader class file require_once __DIR__ . APP_PATH . '/vendor/PopPHPFramework/src/Pop/Loader/Autoloader.php'; // Create the autoloader object and register the Phire application $autoloader = new \Pop\Loader\Autoloader(); $autoloader->splAutoloadRegister(false); $autoloader->register('Phire', __DIR__ . APP_PATH . '/vendor/Phire/src'); // Create the Phire project object $project = \Phire\Project::factory(include __DIR__ . APP_PATH . '/config/project.php', include __DIR__ . APP_PATH . '/vendor/Phire/config/module.php');
<?php /** * Pop PHP Framework (http://www.popphp.org/) * * @link https://github.com/nicksagona/PopPHP * @category Pop * @package Pop_Loader * @author Nick Sagona, III <*****@*****.**> * @copyright Copyright (c) 2009-2014 Moc 10 Media, LLC. (http://www.moc10media.com) * @license http://www.popphp.org/license New BSD License */ /** * IMPORTANT! * * Require the Autoloader class file and instantiate the autoloader object. * If you change the relationship between this file and the framework, * adjust the path accordingly. */ require_once __DIR__ . '/vendor/PopPHPFramework/src/Pop/Loader/Autoloader.php'; $autoloader = new \Pop\Loader\Autoloader(); $autoloader->splAutoloadRegister(); /** * Add any additional custom code or loader features below this doc block. * For example, you can register a third-party library or load a classmap file. * Some examples are: * * $autoloader->register('YourLib', __DIR__ . '/../vendor/YourLib/src'); * $autoloader->loadClassMap('../vendor/YourLib/classmap.php'); */ $autoloader->register('PopSpider', __DIR__ . '/vendor/PopSpider/src');
<?php /** * Pop PHP Framework (http://www.popphp.org/) * * @link https://github.com/nicksagona/PopPHP * @category Pop * @package Pop_Loader * @author Nick Sagona, III <*****@*****.**> * @copyright Copyright (c) 2009-2014 Moc 10 Media, LLC. (http://www.moc10media.com) * @license http://www.popphp.org/license New BSD License */ /** * IMPORTANT! * * Require the Autoloader class file and instantiate the autoloader object. * If you change the relationship between this file and the framework, * adjust the path accordingly. */ require_once __DIR__ . '/../vendor/PopPHPFramework/src/Pop/Loader/Autoloader.php'; $autoloader = new \Pop\Loader\Autoloader(); $autoloader->splAutoloadRegister(); /** * Add any additional custom code or loader features below this doc block. * For example, you can register a third-party library or load a classmap file. * Some examples are: * * $autoloader->register('YourLib', __DIR__ . '/../vendor/YourLib/src'); * $autoloader->loadClassMap('../vendor/YourLib/classmap.php'); */