當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Factory::getParameters方法代碼示例

本文整理匯總了PHP中Factory::getParameters方法的典型用法代碼示例。如果您正苦於以下問題:PHP Factory::getParameters方法的具體用法?PHP Factory::getParameters怎麽用?PHP Factory::getParameters使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Factory的用法示例。


在下文中一共展示了Factory::getParameters方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: parse

 public static function parse()
 {
     if (!self::$mConfigData) {
         $params = Factory::getParameters();
         $file = isset($params['conf']) ? $params['conf'] : DIR_CONF . '/peel.conf';
         self::$mConfigData = parse_ini_file($file, true, INI_SCANNER_NORMAL);
         self::$mConfigData['config_file_path'] = $file;
         self::$mConfigData['config_directory'] = dirname($file);
         self::createDirectories();
         self::parsePeelers();
     }
     return self::$mConfigData;
 }
開發者ID:espena,項目名稱:peel,代碼行數:13,代碼來源:configuration_file.inc.php

示例2: run

 /**
  * Run application.
  *
  * Starts application execution.
  *
  * @return void
  */
 public function run()
 {
     $this->mBase->run();
     $c = $this->getConfig();
     $p = Factory::getParameters();
     $peelerToEnable = isset($p['e']) ? $p['e'] : (isset($p['enable']) ? $p['enable'] : '');
     $peelerToDisable = isset($p['d']) ? $p['d'] : (isset($p['disable']) ? $p['disable'] : '');
     $this->mPathPeelersAvailable = $this->resolvePath($c, 'dir_available');
     $this->mPathPeelersEnabled = $this->resolvePath($c, 'dir_enabled');
     $this->enablePeeler($peelerToEnable);
     $this->disablePeeler($peelerToDisable);
 }
開發者ID:espena,項目名稱:peel,代碼行數:19,代碼來源:app_enabler.inc.php

示例3: define

define('PROFILE_MOD', MODULES . 'profile/');
define('REGISTRATION_MOD', MODULES . 'signup/');
define('WATCH_VIDEO_MOD', MODULES . 'video_watch/');
define('UTILS', LIB . 'utils/');
define('INTERFACES', UTILS . 'interfaces/');
define('VIDEO_UPLOAD_MOD', MODULES . 'video_upload/');
define('VIDEO_SEARCH_MOD', MODULES . 'search/');
define('TMP_VIDEO', LIB . 'tmp_video/');
setReporting(true);
////ALWAYS SET THIS TO 'FALSE' BEFORE DEPLOYING
/** AutoLoad class files as soon as needed ***/
spl_autoload_register('loadClass');
include_once CONFIG . 'settings.php';
$registry = new Registry();
Factory::getRegistry($registry);
Factory::getParameters($parameters);
//parameter is defined in the settings file
// URI will always be of the form /specific_path
$request = $_SERVER["REQUEST_URI"];
$path = explode("/", $request);
$controller_obj = null;
switch ($path[1]) {
    case '':
        $controller_obj = new HomeController($path, $registry);
        $controller_obj->process($_POST);
        break;
    case 'admin':
        $controller_obj = new AdminController($path, $registry);
        $controller_obj->process($_POST);
        break;
    case 'categories':
開發者ID:General-ZOD,項目名稱:eduvideo,代碼行數:31,代碼來源:index.php


注:本文中的Factory::getParameters方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。