当前位置: 首页>>代码示例>>PHP>>正文


PHP GWF_Time::displayTimestamp方法代码示例

本文整理汇总了PHP中GWF_Time::displayTimestamp方法的典型用法代码示例。如果您正苦于以下问题:PHP GWF_Time::displayTimestamp方法的具体用法?PHP GWF_Time::displayTimestamp怎么用?PHP GWF_Time::displayTimestamp使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在GWF_Time的用法示例。


在下文中一共展示了GWF_Time::displayTimestamp方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: deleteOldActivations

 private static function deleteOldActivations(Module_Register $module)
 {
     $cut = time() - $module->getActivationThreshold();
     self::log('Deleting user activations older than ' . GWF_Time::displayTimestamp($cut));
     $table = new GWF_UserActivation(false);
     $result = $table->deleteWhere("timestamp<{$cut}");
     if (0 < ($nDeleted = $table->affectedRows($result))) {
         self::log(sprintf('Deleted %d old user activations.', $nDeleted));
     }
 }
开发者ID:sinfocol,项目名称:gwf3,代码行数:10,代码来源:GWF_RegisterCronjob.php

示例2: checkPeak

 private function checkPeak()
 {
     $channel = Dog::getChannel();
     $count = $channel->getUserCount();
     $peak = Dog_ChannelPeak::getPeak($channel);
     $old_peak = $peak->getVar('lcpeak_peak');
     if ($count > $old_peak) {
         if (!$peak->savePeak($count)) {
             Dog::err('ERR_DATABASE', array(__FILE__, __LINE__));
         } elseif ($old_peak > 0 && $this->hasPeakshow()) {
             $iso = $channel->getLangISO();
             $date = GWF_Time::displayTimestamp(NULL, $iso);
             $channel->sendNOTICE($this->langISO($iso, 'new_peak', array($channel->getName(), Dog::getServer()->displayLongName(), $count, $date)));
         }
     }
 }
开发者ID:sinfocol,项目名称:gwf3,代码行数:16,代码来源:DOGMOD_Peak.php

示例3: displayNote

 public function displayNote(Dog_Server $server, $viewerid)
 {
     $time = $this->getVar('lnote_time');
     $ago = GWF_Time::humanDuration(time() - $time);
     $date = GWF_Time::displayTimestamp($time);
     $from = $this->getVar('lnote_from');
     $to = $this->getVar('lnote_from');
     if ($from == $viewerid) {
         $fromto = 'to';
         $otherid = $to;
     } else {
         $fromto = 'from';
         $otherid = $from;
     }
     $othername = $this->getUsername($otherid);
     $b = chr(2);
     return sprintf($b . 'Note %s %s (%s - %s) ago:' . $b . ' %s (' . $b . 'ID: %s' . $b . ')', $fromto, $othername, $date, $ago, $this->getVar('lnote_msg'), $this->getID());
 }
开发者ID:sinfocol,项目名称:gwf3,代码行数:18,代码来源:Dog_Note.php

示例4: displayDate

 public function displayDate()
 {
     return GWF_Time::displayTimestamp($this->getVar('userhist_date'));
 }
开发者ID:sinfocol,项目名称:gwf3,代码行数:4,代码来源:WC_HistoryUser2.php

示例5: gwfProfileRow

    echo gwfProfileRow(WC_HTML::lang('th_rank2'), GWF_HTML::anchor(GWF_WEB_ROOT . 'ranking/player/' . $u->urlencode2('user_name') . '#rank_' . $rank, $rank));
}
if ($u->getVar('user_countryid') !== '0') {
    if (isset($data['WC_HIDE_RANK'])) {
        echo gwfProfileRow(WC_HTML::lang('th_crank'), $wechall->lang('hidden'));
    } else {
        $cRank = WC_Regat::calcCountryRank($u);
        $href_crank = GWF_WEB_ROOT . 'country_ranking/player/' . $u->urlencode2('user_name') . '#rank_' . $cRank;
        echo gwfProfileRow(WC_HTML::lang('th_crank'), GWF_HTML::anchor($href_crank, $cRank));
    }
}
echo gwfProfileRow($tLang->lang('th_registered'), GWF_Time::displayDate($u->getVar('user_regdate')));
if ($u->isOptionEnabled(GWF_User::HIDE_ONLINE)) {
    $lastactivity = GWF_HTML::lang('unknown');
} else {
    $lastactivity = GWF_Time::displayTimestamp($u->getVar('user_lastactivity'));
}
echo gwfProfileRow($tLang->lang('th_last_active'), $lastactivity);
echo gwfProfileRow($tLang->lang('th_views'), $p->getVar('prof_views'));
if ('' !== ($v = $p->display('prof_firstname'))) {
    echo gwfProfileRow($tLang->lang('th_firstname'), $v);
}
if ('' !== ($v = $p->display('prof_lastname'))) {
    echo gwfProfileRow($tLang->lang('th_lastname'), $v);
}
if ($u->isOptionEnabled(GWF_User::SHOW_BIRTHDAY) && '00000000' !== ($v = $u->getVar('user_birthdate'))) {
    echo gwfProfileRow($tLang->lang('th_age'), GWF_Time::displayAge($v));
    echo gwfProfileRow($tLang->lang('th_birthdate'), GWF_Time::displayDate($v));
}
if ('' !== ($v = $p->display('prof_street'))) {
    echo gwfProfileRow($tLang->lang('th_street'), $v);
开发者ID:sinfocol,项目名称:gwf3,代码行数:31,代码来源:profile.php

示例6: displayRegdate

 public function displayRegdate()
 {
     return GWF_Time::displayTimestamp($this->getVar('regdate'));
 }
开发者ID:sinfocol,项目名称:gwf3,代码行数:4,代码来源:user.php

示例7: array

<?php

$lang = array('en' => array('help' => 'Usage: %CMD% [<timestamp>] [<timezone>]. Convert a unix timestamp to a date.', 'conv' => 'Timestamp %s will be %s.'));
$plugin = Dog::getPlugin();
if ('' === ($message = $plugin->msg())) {
    return $plugin->showHelp();
}
$args = explode(' ', $message);
if (count($args) === 1) {
    $args[] = 'CET';
}
if (count($args) !== 2) {
    return $plugin->showHelp();
}
$plugin->rply('conv', array($args[0], GWF_Time::displayTimestamp($args[0], Dog::getLangISO(), 'Invalid date')));
开发者ID:sinfocol,项目名称:gwf3,代码行数:15,代码来源:date_Pb.php

示例8: smarty_modifier_timestamp

/**
 * Gizmore timestamp modifier
 *
 * Type:     modifier
 * Name:     timestamp
 * Date:     Dec 06, 2011
 * Purpose:  convert a timestamp into human readable date
 * Input:    int to convert
 * Example:  {$var|timestamp:"8"}
 * @author   gizmore
 * @param array $params parameters
 * @return string with compiled code
 */
function smarty_modifier_timestamp($timestamp)
{
    return GWF_Time::displayTimestamp($timestamp, NULL, 'Never');
}
开发者ID:sinfocol,项目名称:gwf3,代码行数:17,代码来源:modifier.timestamp.php

示例9: array

<?php

echo $tVars['search_form'];
$headers = array(array($tLang->lang('th_userid'), 'user_id', 'ASC'), array($tLang->lang('th_user_credits'), 'user_credits', 'ASC'), array($tLang->lang('th_user_level'), 'user_level', 'ASC'), array($tLang->lang('th_country'), 'user_countryid', 'ASC'), array($tLang->lang('th_user_name'), 'user_name', 'ASC'), array($tLang->lang('th_regdate'), 'user_regdate', 'ASC'), array($tLang->lang('th_email'), 'user_email', 'ASC'), array($tLang->lang('th_birthdate'), 'user_birthdate', 'ASC'), array($tLang->lang('th_regip'), 'user_regip', 'ASC'), array($tLang->lang('th_lastactivity'), 'user_lastactivity', 'DESC'));
echo $tVars['pagemenu'];
echo GWF_Table::start();
echo GWF_Table::displayHeaders1($headers);
foreach ($tVars['users'] as $user) {
    echo GWF_Table::rowStart();
    $user instanceof GWF_User;
    $href = Module_Admin::getUserEditURL($user->getID());
    echo GWF_Table::column(GWF_HTML::anchor($href, $user->getID()), 'gwf_num');
    echo GWF_Table::column(GWF_HTML::anchor($href, round($user->getVar('user_credits')), 2), 'gwf_num');
    echo GWF_Table::column(GWF_HTML::anchor($href, $user->getLevel()), 'gwf_num');
    echo GWF_Table::column(sprintf('<a href="%s">%s</a>', $href, $user->displayCountryFlag()));
    echo GWF_Table::column(GWF_HTML::anchor($href, $user->display('user_name')));
    echo GWF_Table::column(GWF_HTML::anchor($href, GWF_Time::displayDate($user->getVar('user_regdate'))), 'gwf_date');
    echo GWF_Table::column(GWF_HTML::anchor($href, $user->display('user_email')));
    echo GWF_Table::column(GWF_HTML::anchor($href, GWF_Time::displayDate($user->getVar('user_birthdate'))), 'gwf_date');
    echo GWF_Table::column(GWF_HTML::anchor($href, GWF_IP6::displayIP($user->getVar('user_regip'), GWF_IP_EXACT)));
    echo GWF_Table::column(GWF_HTML::anchor($href, GWF_Time::displayTimestamp($user->getVar('user_lastactivity'))), 'gwf_date');
    echo GWF_Table::rowEnd();
}
echo GWF_Table::end();
echo $tVars['pagemenu'];
开发者ID:sinfocol,项目名称:gwf3,代码行数:25,代码来源:users.php

示例10: displayTimestamp

 public function displayTimestamp()
 {
     return GWF_Time::displayTimestamp($this->getVar('timestamp'));
 }
开发者ID:sinfocol,项目名称:gwf3,代码行数:4,代码来源:GWF_UserActivation.php


注:本文中的GWF_Time::displayTimestamp方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。