本文整理汇总了PHP中WC_HTML::message方法的典型用法代码示例。如果您正苦于以下问题:PHP WC_HTML::message方法的具体用法?PHP WC_HTML::message怎么用?PHP WC_HTML::message使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类WC_HTML
的用法示例。
在下文中一共展示了WC_HTML::message方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: insertEntry
public static function insertEntry($siteid, $score, $usercount, $challcount, $comment = '')
{
$entry = new self(array('sitehist_sid' => $siteid, 'sitehist_date' => time(), 'sitehist_score' => $score, 'sitehist_usercount' => $usercount, 'sitehist_challcount' => $challcount, 'sitehist_comment' => $comment));
if (WECHALL_DEBUG_SCORING) {
echo WC_HTML::message('Inserting Site History Item...');
}
return $entry->insert();
}
示例2: insertEntry
public static function insertEntry(GWF_User $user, WC_Site $site, $onsitescore, $comment)
{
$user = GWF_User::getByID($user->getID());
$max = $site->getOnsiteScore();
$perc = $max <= 0 ? 0 : round($onsitescore / $max * 10000);
$entry = new self(array('userhist_uid' => $user->getVar('user_id'), 'userhist_date' => time(), 'userhist_sid' => $site->getVar('site_id'), 'userhist_percent' => $perc, 'userhist_onsitescore' => $onsitescore, 'userhist_rank' => WC_RegAt::calcRank($user), 'userhist_totalscore' => $user->getVar('user_level'), 'userhist_comment' => $comment));
if (WECHALL_DEBUG_SCORING) {
echo WC_HTML::message('Inserting User History entry...');
}
return $entry->insert();
}
示例3: insertEntry
public static function insertEntry(GWF_User $user, WC_Site $site, $type, $onsitescore_new = 0, $onsitescore_old = 0, $scoregain = 0, $onsiterank = 0)
{
$uid = $user->getID();
$user = GWF_User::getByID($uid);
$max = $site->getOnsiteScore();
$perc_new = $max <= 0 ? 0 : round($onsitescore_new / $max * 10000);
$perc_old = $max <= 0 ? 0 : round($onsitescore_old / $max * 10000);
$perc_gain = $perc_new - $perc_old;
$options = 0;
$data = $user->getUserData();
if (isset($data['WC_NO_XSS'])) {
$options |= self::NO_XSS;
}
$entry = new self(array('userhist_uid' => $uid, 'userhist_date' => time(), 'userhist_sid' => $site->getID(), 'userhist_percent' => $perc_new, 'userhist_onsitescore' => $onsitescore_new, 'userhist_rank' => WC_RegAt::calcExactRank($user), 'userhist_totalscore' => $user->getVar('user_level'), 'userhist_gain_perc' => $perc_gain, 'userhist_gain_score' => $scoregain, 'userhist_type' => $type, 'userhist_onsiterank' => $onsiterank, 'userhist_options' => $options));
if (WECHALL_DEBUG_SCORING) {
echo WC_HTML::message('Inserting User History entry...');
}
return $entry->insert();
}
示例4: recalcSite
/**
* Recalc and update all scores for this site.
* @return void
*/
public function recalcSite()
{
require_once 'WC_RegAt.php';
if (WECHALL_DEBUG_SCORING) {
echo WC_HTML::message('msg_site_recalc', array($this->displayName()));
}
$this->recalcAverage();
$this->recalcScore();
WC_RegAt::calcSite($this);
WC_RegAt::calcTotalscores();
}