hehexu

博客园 首页 新随笔 联系 订阅 管理
foreach ($modules AS $key => $value)
{
ksort($modules[$key]);
}
ksort($modules);

strpos(','.$_SESSION['action_list'].',',','.$priv_str.',')===false)

json_decode(string $json [, bool $assoc ]) 接受一个 JSON 格式的字符串并且
把它转换为 PHP 变量

当该参数为 TRUE 时,将返回 array 而非 object 。 

function local_getdate($timestamp = NULL)
{
$timezone = isset($_SESSION['timezone']) ? $_SESSION['timezone'] : $GLOBALS['_CFG']['timezone'];

/* 如果时间戳为空,则获得服务器的当前时间 */
if ($timestamp === NULL)
{
$timestamp = time();
}

$gmt = $timestamp - date('Z'); // 得到该时间的格林威治时间
$local_time = $gmt + ($timezone * 3600); // 转换为用户所在时区的时间戳

return getdate($local_time);
}
 

 



js

 

 

 
posted on 2018-08-14 21:13  hehexu  阅读(360)  评论(0编辑  收藏  举报