本文整理汇总了PHP中M::SESSION_TTL方法的典型用法代码示例。如果您正苦于以下问题:PHP M::SESSION_TTL方法的具体用法?PHP M::SESSION_TTL怎么用?PHP M::SESSION_TTL使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类M
的用法示例。
在下文中一共展示了M::SESSION_TTL方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: foreach
<?php
require_once 'server/settings.global.php';
require_once 'server/settings.project.php';
require_once 'server/settings.host.php';
/********************************************************/
foreach ($_ENV['PROJECT_SETTINGS'] as $sKey => $sValue) {
$_ENV['SETTINGS'][$sKey] = $sValue;
}
foreach ($_ENV['HOST_SETTINGS'] as $sKey => $sValue) {
$_ENV['SETTINGS'][$sKey] = $sValue;
}
/********************************************************/
session_set_cookie_params(M::SESSION_TTL());
session_name($_ENV['SETTINGS']['SESSION_NAME']);
session_start();
mb_internal_encoding('UTF-8');
$_ENV['SETTINGS']['BUILD_ID'] = '';
if (file_exists($_ENV['SETTINGS']['PROJECT_ROOT'] . '/build')) {
$_ENV['SETTINGS']['BUILD_ID'] = file_get_contents($_ENV['SETTINGS']['PROJECT_ROOT'] . '/build');
}
$_ENV['LAST_EVALED_FILE'] = null;
$_ENV['EVAL_ERROR'] = false;
$_ENV['SETTINGS']['FILE_LOG_PHP'] = $_ENV['SETTINGS']['PROJECT_ROOT'] . '/' . $_ENV['SETTINGS']['PATH_LOGS'] . '/' . $_ENV['SETTINGS']['FILE_LOG_PHP'];
$_ENV['SETTINGS']['FILE_LOG_PHANTOM'] = $_ENV['SETTINGS']['PROJECT_ROOT'] . '/' . $_ENV['SETTINGS']['PATH_LOGS'] . '/' . $_ENV['SETTINGS']['FILE_LOG_PHANTOM'];
$_ENV['SETTINGS']['FILE_LOG_CSS'] = $_ENV['SETTINGS']['PROJECT_ROOT'] . '/' . $_ENV['SETTINGS']['PATH_LOGS'] . '/' . $_ENV['SETTINGS']['FILE_LOG_CSS'];
$_ENV['SETTINGS']['PROTOCOL'] = Request::isHttps() ? 'https' : 'http';
$_ENV['SETTINGS']['HTTP_ROOT'] = 'http://' . $_ENV['SETTINGS']['HOST'] . ($_ENV['SETTINGS']['HTTP_PORT'] != 80 ? ':' . $_ENV['SETTINGS']['HTTP_PORT'] : '') . $_ENV['SETTINGS']['SITE_PATH'];
$_ENV['SETTINGS']['HTTPS_ROOT'] = 'https://' . $_ENV['SETTINGS']['HOST'] . ($_ENV['SETTINGS']['HTTPS_PORT'] != 443 ? ':' . $_ENV['SETTINGS']['HTTPS_PORT'] : '') . $_ENV['SETTINGS']['SITE_PATH'];
$_ENV['SETTINGS']['AGNOSTIC_ROOT'] = '//' . $_ENV['SETTINGS']['HOST'] . $_ENV['SETTINGS']['SITE_PATH'];
// $_ENV['SETTINGS']['REQUEST_PATH'] = isset($_SERVER['REQUEST_URI'])