โค้ด: เลือกทั้งหมด
function page_header($page_title = '', $display_online_list = false, $item_id = 0, $item = 'forum')
{
global $user;
$this->template->assign_vars(array(
'TOTAL_TIME_LOGGED_IN' => $user->format_date(time(), $format, true),
));
}
โค้ด: เลือกทั้งหมด
$this->template->assign_vars(array(
'TOTAL_TIME_LOGGED_IN' => $user->format_date($user->data['user_dateformat']),
));
Fatal error: Uncaught exception 'Exception' with message 'DateTime::__construct(): Failed to parse time string (@F jS, Y, g:i a) at position 0 (@): Unexpected character' in E:\xampp\htdocs\phpbb_rc2_new\phpbb\datetime.php:50 Stack trace: #0 E:\xampp\htdocs\phpbb_rc2_new\phpbb\datetime.php(50): DateTime->__construct('@F jS, Y, g:i a', Object(DateTimeZone)) #1 E:\xampp\htdocs\phpbb_rc2_new\phpbb\user.php(713): phpbb\datetime->__construct(Object(phpbb\user), '@F jS, Y, g:i a', Object(DateTimeZone)) #2 E:\xampp\htdocs\phpbb_rc2_new\ext\midphp\m_user_online_time\event\listener.php(80): phpbb\user->format_date('F jS, Y, g:i a') #3 [internal function]: midphp\m_user_online_time\event\listener->page_header(Object(phpbb\event\data)) #4 E:\xampp\htdocs\phpbb_rc2_new\vendor\symfony\http-kernel\Symfony\Component\HttpKernel\Debug\TraceableEventDispatcher.php(457): call_user_func(Array, Object(phpbb\event\data)) #5 [internal function]: Symfony\Component\HttpKernel\Debug\TraceableEventDispatcher->Symfony\Component\HttpKernel\Debug\{clos in E:\xampp\htdocs\phpbb_rc2_new\phpbb\datetime.php on line 50