本文整理匯總了PHP中XoopsBaseConfig::bootstrapTransition方法的典型用法代碼示例。如果您正苦於以下問題:PHP XoopsBaseConfig::bootstrapTransition方法的具體用法?PHP XoopsBaseConfig::bootstrapTransition怎麽用?PHP XoopsBaseConfig::bootstrapTransition使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類XoopsBaseConfig
的用法示例。
在下文中一共展示了XoopsBaseConfig::bootstrapTransition方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: define
// Shall be handled later, don't forget!
define("XOOPS_CHECK_PATH", 0);
// Protect against external scripts execution if safe mode is not enabled
if (XOOPS_CHECK_PATH && !@ini_get("safe_mode")) {
if (function_exists("debug_backtrace")) {
$xoopsScriptPath = debug_backtrace();
if (!count($xoopsScriptPath)) {
die("XOOPS path check: this file cannot be requested directly");
}
$xoopsScriptPath = $xoopsScriptPath[0]["file"];
} else {
$xoopsScriptPath = isset($_SERVER["PATH_TRANSLATED"]) ? $_SERVER["PATH_TRANSLATED"] : $_SERVER["SCRIPT_FILENAME"];
}
if (DIRECTORY_SEPARATOR != "/") {
// IIS6 may double the \ chars
$xoopsScriptPath = str_replace(strpos($xoopsScriptPath, "\\\\", 2) ? "\\\\" : DIRECTORY_SEPARATOR, "/", $xoopsScriptPath);
}
if (strcasecmp(substr($xoopsScriptPath, 0, strlen(XOOPS_ROOT_PATH)), str_replace(DIRECTORY_SEPARATOR, "/", XOOPS_ROOT_PATH))) {
exit("XOOPS path check: Script is not inside XOOPS_ROOT_PATH and cannot run.");
}
}
// Secure file
require XOOPS_VAR_PATH . '/data/secure.php';
if (!class_exists('XoopsBaseConfig', false)) {
include __DIR__ . '/class/XoopsBaseConfig.php';
XoopsBaseConfig::bootstrapTransition();
}
if (!isset($xoopsOption["nocommon"]) && XOOPS_ROOT_PATH != "") {
include XOOPS_ROOT_PATH . "/include/common.php";
}
}