本文整理匯總了PHP中TikiLib::get_preferences方法的典型用法代碼示例。如果您正苦於以下問題:PHP TikiLib::get_preferences方法的具體用法?PHP TikiLib::get_preferences怎麽用?PHP TikiLib::get_preferences使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類TikiLib
的用法示例。
在下文中一共展示了TikiLib::get_preferences方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: TikiDate
'memcache_enabled' => 'n',
'memcache_expiration' => 3600,
'memcache_prefix' => 'tiki_',
'memcache_compress' => 'y',
'memcache_servers' => false,
'min_pass_length' => 5,
'pass_chr_special' => 'n',
'smarty_compilation' => 'modified',
);
// check that tiki_preferences is there
if ($tikilib->query("SHOW TABLES LIKE 'tiki_preferences'")->numRows() == 0) {
// smarty not initialised at this point to do a polite message, sadly
header('location: tiki-install.php');
exit;
}
$tikilib->get_preferences($needed_prefs, true, true);
if ($prefs['session_protected'] == 'y' && ! isset($_SERVER['HTTPS'])) {
header("Location: https://{$_SERVER['HTTP_HOST']}{$_SERVER['REQUEST_URI']}");
exit;
}
global $cachelib;
require_once ('lib/cache/cachelib.php');
global $logslib;
require_once ('lib/logs/logslib.php');
include_once ('lib/init/tra.php');
require_once ('lib/tikidate.php');
$tikidate = new TikiDate();
// set session lifetime
if ($prefs['session_lifetime'] > 0) {