当前位置: 首页>>代码示例>>PHP>>正文


PHP WoW::CatchOperations方法代码示例

本文整理汇总了PHP中WoW::CatchOperations方法的典型用法代码示例。如果您正苦于以下问题:PHP WoW::CatchOperations方法的具体用法?PHP WoW::CatchOperations怎么用?PHP WoW::CatchOperations使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在WoW的用法示例。


在下文中一共展示了WoW::CatchOperations方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: die

        if (!file_exists($classFileName)) {
            die('<strong>Autoload Fatal Error:</strong> unable to autoload class ' . $className . ' (path: ' . $classFileName . ')!');
        }
        include $classFileName;
    }
}
// Initialize debug log
WoW_Log::Initialize(WoWConfig::$UseLog, WoWConfig::$LogLevel);
// Load databases configs
// Do not create DB connections here - it will be created automatically at first query request!
DB::LoadConfigs();
// Core self testing
WoW::SelfTests();
// Try to catch some operations (login, logout, etc.)
$locale_loaded = false;
WoW::CatchOperations($locale_loaded);
// locale from page controller
$wow_locale_cms = isset($_COOKIE['wow_locale']) ? $_COOKIE['wow_locale'] : WoWConfig::$DefaultLocale;
if (!isset($_COOKIE['wow_locale'])) {
    setcookie('wow_locale', $wow_locale_cms, strtotime('NEXT YEAR'), '/');
    $_COOKIE['wow_locale'] = $wow_locale_cms;
}
$pController = new PageController();
if ($pController->GetLocale() != null && $pController->GetLocale() != $_COOKIE['wow_locale']) {
    //$_SESSION['wow_locale'] = $pController->GetLocale();
    WoW_Locale::SetLocale($pController->GetLocale(), WoW_Locale::GetLocaleIDForLocale($pController->GetLocale()), true);
} else {
    WoW_Locale::SetLocale($_COOKIE['wow_locale'], WoW_Locale::GetLocaleIDForLocale($_COOKIE['wow_locale']));
}
// Initialize account (if user already logged in we need to re-build his info from session data)
WoW_Account::Initialize();
开发者ID:JunkyBulgaria,项目名称:WoWCS,代码行数:31,代码来源:WoW_Loader.php


注:本文中的WoW::CatchOperations方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。