本文整理汇总了PHP中StatusNet::loadConfigFile方法的典型用法代码示例。如果您正苦于以下问题:PHP StatusNet::loadConfigFile方法的具体用法?PHP StatusNet::loadConfigFile怎么用?PHP StatusNet::loadConfigFile使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类StatusNet
的用法示例。
在下文中一共展示了StatusNet::loadConfigFile方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: init
/**
* Initialize, or re-initialize, StatusNet global configuration
* and plugins.
*
* If switching site configurations during script execution, be
* careful when working with leftover objects -- global settings
* affect many things and they may not behave as you expected.
*
* @param $server optional web server hostname for picking config
* @param $path optional URL path for picking config
* @param $conffile optional configuration file path
*
* @throws NoConfigException if config file can't be found
*/
public static function init($server = null, $path = null, $conffile = null)
{
StatusNet::initDefaults($server, $path);
StatusNet::loadConfigFile($conffile);
// Load settings from database; note we need autoload for this
Config::loadSettings();
self::initPlugins();
}
示例2: init
/**
* Initialize, or re-initialize, StatusNet global configuration
* and plugins.
*
* If switching site configurations during script execution, be
* careful when working with leftover objects -- global settings
* affect many things and they may not behave as you expected.
*
* @param $server optional web server hostname for picking config
* @param $path optional URL path for picking config
* @param $conffile optional configuration file path
*
* @throws NoConfigException if config file can't be found
*/
public static function init($server = null, $path = null, $conffile = null)
{
Router::clear();
StatusNet::initDefaults($server, $path);
StatusNet::loadConfigFile($conffile);
$sprofile = common_config('site', 'profile');
if (!empty($sprofile)) {
StatusNet::loadSiteProfile($sprofile);
}
// Load settings from database; note we need autoload for this
Config::loadSettings();
self::initPlugins();
}