本文整理汇总了PHP中zin函数的典型用法代码示例。如果您正苦于以下问题:PHP zin函数的具体用法?PHP zin怎么用?PHP zin使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了zin函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: run
public function run()
{
$user = $this->order[$this->is_emp ? 'freelancer' : 'employer'];
//получаем общее кол-во отзывов
$oplinks = NULL;
$opcount = opinions::GetCounts($user['uid'], array('total'));
if (array_sum($opcount['total']) > 0) {
$oplinks = array('p' => getSortOpinionLinkEx('frl', "total", 1, $user['login'], zin($opcount['total']['p']), null, 0), 'n' => getSortOpinionLinkEx('frl', "total", 2, $user['login'], zin($opcount['total']['n']), null, 0), 'm' => getSortOpinionLinkEx('frl', "total", 3, $user['login'], zin($opcount['total']['m']), null, 0));
}
//город юзера
$city_id = $this->order['is_meet'] == 't' && $this->order['city'] > 0 ? $this->order['city'] : $user['city'];
$user['place_title'] = '';
if ($city_id > 0) {
$user['place_title'] = city::getCountryName($city_id) . ', ' . city::getCityName($city_id);
}
//собираем шаблон
$this->render('t-service-order-user-profile', array('user' => $user, 'oplinks' => $oplinks));
}
示例2: process_batch
/**
* Обработка пачки событий (вызывается демоном).
*
* @param int $batch_id
*
* @return bool
*/
public function process_batch($batch_id)
{
$events = $this->preprocess_batch($batch_id);
if ($events === false) {
$this->log->verbose('PGQDaemonBanners.preprocess_batch got not events (False).');
return false;
}
/*
* Event processing loop!
*/
$abort_batch = false;
$sql = "PREPARE updBanners (int, int, int) AS \n \t\tUPDATE ban_stats1 set views = views + \$2, clicks = clicks + \$3 WHERE banner_id = \$1;\n";
foreach ($events as $event) {
if ($abort_batch) {
break;
}
$id = $event->data['id'];
$type = $event->type;
if ($type == 'click') {
++$bans[$id]['click'];
} elseif ($type == 'view') {
++$bans[$id]['view'];
}
$this->log->verbose('PGQDaemonBanners.process_batch type %s event %d of batch %d ', $type, $event->id, $batch_id);
$this->log->verbose('PGQDaemonBanners.process_batch processed event %d of batch %d', $event->id, $batch_id);
}
if ($bans) {
foreach ($bans as $ikey => $ban) {
$sql .= "EXECUTE updBanners({$ikey}, " . zin($ban['view']) . ', ' . zin($ban['click']) . ");\n";
}
$sql .= 'DEALLOCATE updBanners;';
$result = pg_query(DBConnect(), $sql);
$this->log->debug('UPDATE : %s ', $sql);
if ($result === false) {
$this->log->error('Unable to update : %s ', $sql);
$abort_batch = true;
}
} else {
$this->log->verbose('PGQDaemonBanners.process_batch has no banners');
}
return $this->postprocess_batch($batch_id, $abort_batch);
}
示例3: zin
echo $user->login;
?>
#form" method="post"><input type="hidden" name="prjname" value="<?php
echo $prj['name'] ? $prj['name'] : 'заголовок отсутствует';
?>
"><input type="submit" name="btn" class="btn" value="Оговорить детали"></form><?php
}
?>
<div align="right" style="margin-top: 5px;"><b>[<a href="<?/* Апдейт проектов /blogs/view.php?tr=<?php
echo $prj['thread_id'];
?>
*/?>/projects/?pid=<?php
echo $prj['id'];
?>
" class="blue"><b>Комментарии (<?php
echo zin($prj['comm_count']);
?>
)</b></a>]</b></div>
</td>
</tr>
</table>
<?php
} else {
?>
<table width="100%" border="0" cellspacing="0" cellpadding="19">
<tr valign="top">
<td height="400" valign="top" bgcolor="#FFFFFF">
<h1>Проект удален</h1>
К сожалению, этот проект был удален.<br>
<br>
Электронная почта: <a href="mailto:info@free-lance.ru">info@free-lance.ru</a><br>
示例4: setlocale
Сумма к оплате: <span id="quick_pro_sum_pay"></span> руб.<br>
</div>
<div class="b-layout__txt b-layout__txt_padbot_20 b-layout__txt_padleft_20 b-layout__txt_fontsize_11">
<span id="quick_pro_sum_span_4">
<span id="quick_pro_sum_span_2">Часть суммы (<span id="quick_pro_sum_span_7"></span> руб.)</span><span id="quick_pro_sum_span_3">Она</span> будет списана с личного счета, на нем
<span id="quick_pro_sum_account1" class="b-layout__bold">
<?php
setlocale(LC_NUMERIC, 'en_US');
?>
<?php
if (round($_SESSION['bn_sum'] + $_SESSION['ac_sum'], 2) > 0) {
?>
<?php
echo number_format(round(zin($_SESSION['ac_sum']), 2), 2, ",", " ");
?>
<?php
} else {
?>
0
<?php
}
?>
</span>
руб.<br>
<span id="quick_pro_sum_span_5">
Остаток (<span id="quick_pro_sum_span_6"></span> руб.) вам нужно оплатить одним из способов:
</span>
</span>
<span id="quick_pro_sum_span_1">Ее вы можете оплатить одним из способов:</span>
示例5: url
$theme = $groups[$i];
if (in_array($theme['id'], blogs::$copiny_group)) {
$feedback_copiny[] = $theme;
continue;
// Перенесли в архив #0023264
}
$love = (int) $theme['id'] == 55;
if ($love && !$allow_love) {
continue;
}
$tname = $theme['t_name'];
//if ($theme['id'] == 7 && $theme['t'] == 0) $tname = "<strong>".$theme['t_name']."</strong>";
if ($theme['id'] == $gr && $base == $theme['t']) {
$group_line .= $addit . "<li" . ($love ? ' style="background: url(/images/icons/heart.png) no-repeat 2px 7px;" ' : '') . ($i == $size - 1 ? " class=\"last\"" : "") . ">" . ($love ? '<span id="love_time_simple" style="float:right">00:00:00</span>' : '') . $theme['t_name'] . " (" . zin($theme['num']) . ")</li>\n";
} else {
$group_line .= $addit . "<li" . ($love ? ' style="background: url(/images/icons/heart.png) no-repeat 2px 7px;" ' : '') . ($i == $size - 1 ? " class=\"last\"" : "") . ">" . ($love ? '<span id="love_time_simple" style="float:right">00:00:00</span>' : '') . "<a href=\"" . getFriendlyUrl('blog_group', $theme['id']) . ($theme['t'] || $ord ? "?" : "") . ($theme['t'] ? "&t=prof" : "") . ($ord != "new" ? "&ord={$ord}" : "") . "\" title=\"" . $theme['t_name'] . "\">" . $tname . " (" . zin($theme['num']) . ")</a></li>\n";
}
$sum = $sum + $theme['num'];
}
?>
<li><?php
if ($gr) {
?>
<a href="/blogs/viewgroup.php<?php
echo $ord ? "?ord={$ord}" : "";
?>
" title="Все вместе"><?php
}
?>
<strong>Все вместе</strong> (<?php
echo $sum;
示例6: view_account_format
/**
* Форматтер состояния счета в шапке
*
* @return string
*/
function view_account_format($tip = FALSE)
{
$ac_sum = round(zin($_SESSION['ac_sum']), 2);
$bn_sum = round(zin($_SESSION['bn_sum']), 2);
$ac_sum_txt = number_format($ac_sum, 2, ",", " ");
$bn_sum_txt = number_format($bn_sum, 2, ",", " ");
$ret = $tip ? "У вас на счету {$ac_sum_txt} " . ending($ac_sum, 'рубль', 'рубля', 'рублей') : $ac_sum_txt . ((int) $_SESSION['bn_sum'] ? ' + ' . $bn_sum_txt : '') . ' руб.';
$ret = str_replace(',00', '', $ret);
return $ret;
}
示例7: Auth
//.........这里部分代码省略.........
$res = array();
//переходим ко 2ой стадии
return self::AUTH_STATUS_2FA;
}
}
}
//Более нам параметр этапов авторизации не нужен
unset($params['2fa_provider']);
/**
* Успешная авторизация.
*/
if (count($res)) {
list($email, $trole, $tname, $tsurname, $tid, $is_banned, $ban_where, $active, $sum, $bonus_sum, $log, $anti_uid, $is_pro_test, $is_pro_new, $is_chuck, $sex, $settings, $splash_show, $is_verify, $reg_date, $activate_code, $photo, $is_profi, $birthday) = array_values($res);
if ($activate_code != '' && $active == 't') {
$this->checkRegDate($tid, $reg_date);
}
if ($is_banned) {
return -1;
}
//if ($active=='f') return -2; //##0027983
if (!$this->CheckUserAllowIP($ip, $tid)) {
return -3;
}
$params['birthday'] = $birthday ? strtotime($birthday) : null;
$params['age'] = $params['birthday'] ? intval(ElapsedYears($params['birthday'])) : null;
require_once $_SERVER['DOCUMENT_ROOT'] . '/classes/permissions.php';
$params['permissions'] = permissions::getUserPermissions($tid);
$params['email'] = $email;
$params['role'] = $trole;
$params['name'] = $tname;
$params['surname'] = $tsurname;
$params['uid'] = $tid;
$params['user_ip'] = $ip;
$params['ac_sum'] = zin($sum);
$params['bn_sum'] = zin($bonus_sum);
$params['login'] = $log;
$params['is_pro_new'] = $is_pro_new;
$params['pro_test'] = $is_pro_test;
$params['is_chuck'] = $is_chuck;
$params['is_verify'] = $is_verify;
$params['sex'] = $sex;
$params['reg_date'] = $reg_date;
$params['photo'] = $photo;
if (!is_emp($trole)) {
$params['is_profi'] = $is_profi === 't';
}
if ($anti_uid) {
$anti_class = is_emp($trole) ? 'freelancer' : 'employer';
require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/{$anti_class}.php";
$anti = new $anti_class();
$anti->GetUserByUID($anti_uid);
$params['anti_uid'] = $anti->uid;
$params['anti_login'] = $anti->login;
$params['anti_surname'] = $anti->usurname;
$params['anti_name'] = $anti->uname;
}
if (!is_emp($params['role'])) {
require_once $_SERVER['DOCUMENT_ROOT'] . '/classes/projects_offers.php';
if ($po_summary = projects_offers::GetFrlOffersSummary($params['uid'])) {
$params['po_count'] = $po_summary['total'];
}
}
$sql = 'UPDATE users SET last_time = now(), last_ip = ?, is_active = true WHERE uid = ?i';
$res = $DB->query($sql, $ip, $tid);
$this->SaveLoginIPLog($tid, $ip);
$this->increaseLoginsCnt($tid);
示例8: zin
echo $prj['thread_id'];
?>
" class="blue">
<?php
echo $prj['comm_count'] ? '<b>Комментарии (' . zin($prj['comm_count']) . ')</b>' : 'Комментарии (' . zin($prj['comm_count']) . ')';
?>
</a>]</b>
</div><?php
} else {
?>
<div align="right" style="margin-top: 5px;"><b>[<a href="/projects/?pid=<?php
echo $prj['id'];
?>
" class="blue">
<?php
echo $prj['offers_count'] ? '<b>Комментарии (' . zin($prj['offers_count']) . ')</b>' : 'Комментарии (' . zin($prj['offers_count']) . ')';
?>
</a>]</b>
</div><?php
}
?>
</td>
<td width="67" align="center" class="qp"><?if ($prj['cost']>0) {?><strong><?php
echo CurToChar($prj['cost'], $prj['currency']);
?>
</strong><?} else{?> <?}?></td>
<td width="30"><?php
if ($prj['closed'] == 't') {
?>
Проект закрыт<?php
} else {
示例9: getHeaderData
/**
* Возвращает html заголовка страницы с отзывами в массиве
*
* @param string $from (frl|my|emp|norisk) параметр from
* @param users $user пользователь, на странице которого мы в данный момент находимся
* @param integer $to_id пользователь, для которго мы готовим вывод
* @return array html заголовка страницы с отзывами в массиве
*/
public static function getHeaderData($from, $user, $to_id)
{
$opcount = opinions::GetCounts($to_id, array('emp', 'norisk', 'frl', 'all', 'total'));
$out = array();
/*
* @todo: неиспользуется?
*
*
$out['all'] = getSortOpinionLinkEx($from, "users", 1, $user->login, zin($opcount['all']['p']))
. ' ' . getSortOpinionLinkEx($from, "users", 2, $user->login, zin($opcount['all']['n']))
. ' ' . getSortOpinionLinkEx($from, "users", 3, $user->login, zin($opcount['all']['m']));
$out['emp'] = getSortOpinionLinkEx($from, "emp", 1, $user->login, zin($opcount['emp']['p']))
. ' ' . getSortOpinionLinkEx($from, "emp", 2, $user->login, zin($opcount['emp']['n']))
. ' ' . getSortOpinionLinkEx($from, "emp", 3, $user->login, zin($opcount['emp']['m']));
$out['frl'] = getSortOpinionLinkEx($from, "frl", 1, $user->login, zin($opcount['frl']['p']))
. ' ' . getSortOpinionLinkEx($from, "frl", 2, $user->login, zin($opcount['frl']['n']))
. ' ' . getSortOpinionLinkEx($from, "frl", 3, $user->login, zin($opcount['frl']['m']));
$out['norisk'] = getSortOpinionLinkEx($from, "norisk", 1, $user->login, zin($opcount['norisk']['p']))
. ' ' . getSortOpinionLinkEx($from, "norisk", 2, $user->login, zin($opcount['norisk']['n']))
. ' ' . getSortOpinionLinkEx($from, "norisk", 3, $user->login, zin($opcount['norisk']['m']));
$out['total'] = getSortOpinionLinkEx($from, "total", 1, $user->login, zin($opcount['total']['p']))
. ' ' . getSortOpinionLinkEx($from, "total", 2, $user->login, zin($opcount['total']['n']))
. ' ' . getSortOpinionLinkEx($from, "total", 3, $user->login, zin($opcount['total']['m']));
*/
$out['total_no_author'] = getSortOpinionLinkEx($from, "total", 1, $user->login, zin($opcount['total']['p']), null, 0) . ' ' . getSortOpinionLinkEx($from, "total", 2, $user->login, zin($opcount['total']['n']), null, 0) . ' ' . getSortOpinionLinkEx($from, "total", 3, $user->login, zin($opcount['total']['m']), null, 0);
return $out;
}
示例10: zin
?>
</td>
<td class="b-layout__td b-layout__td_padtb_15 b-layout__td_valign_mid b-page__desktop">
<div class="b-layout__txt b-layout__txt_color_64 b-layout__txt_fontsize_15 b-layout__txt_bold b-layout__txt_center">
<a class="b-layout__link b-layout__link_color_6db335 b-layout__link_bold b-layout_hover_link_decorated" href="/users/<?php
echo $frl['login'];
?>
/opinions/?sort=1&author=0">+ <?php
echo zin($frl['total_opi_plus']);
?>
</a> |
<a class="b-layout__link b-layout__link_bold b-layout__link_color_c10600 b-layout_hover_link_decorated" href="/users/<?php
echo $frl['login'];
?>
/opinions/?sort=3&author=0">- <?php
echo zin($frl['total_opi_minus']);
?>
</a>
</div>
</td>
<td class="b-layout__td b-layout__td_padleft_20 b-layout__td_padright_20 b-layout__td_padtb_15 b-layout__td_valign_mid">
<div class="b-layout__txt b-layout__txt_color_64 b-layout__txt_fontsize_11">
<?php
echo br2br(LenghtFormatEx(reformat($frl['status_text'], 40, 0, 1, 25), 150));
?>
</div>
</td>
</tr>
<?php
if ($i < $cntCatalogList - 1) {
?>
示例11: zin
% (<a href="/siteadmin/users/?action=selacop&fdate=<?php
echo $fdate;
?>
&tdate=<?php
echo $tdate;
?>
&akop=45" class="blue">операций: <?php
echo zin($mass_sending_a[$i]['cnt']);
?>
</a>)
<br>
Отказанные: <?php
echo zin(abs($mass_sending_r[$i]['sum']));
?>
руб. (операций: <?php
echo zin(abs($mass_sending_r[$i]['cnt']));
?>
)
</td>
</tr>
</table>
<?php
}
?>
<br><br>
<div style="margin-bottom: 50px"></div>
<?php
示例12: getOpinionLinks
function getOpinionLinks($login, $value)
{
return getSortOpinionLinkEx(0, 1, 1, $login, zin($value['total_opi_plus']), null, 0) . ' ' . getSortOpinionLinkEx(0, 1, 2, $login, zin($value['total_opi_null']), null, 0) . ' ' . getSortOpinionLinkEx(0, 1, 3, $login, zin($value['total_opi_minus']), null, 0);
}
示例13: round
<?php
echo $user->usurname;
?>
[<?php
echo $user->login;
?>
]</a><br>
Номер счета: <?php
echo $account->id;
?>
<h3 style="margin-bottom:0px;">На счету <?php
echo round($account->sum, 2);
?>
руб.</h3>
<strong>на бонусном счету - <?php
echo zin(round($account->bonus_sum, 2));
?>
руб.</strong><br /><br />
<?php
if (!is_release() || in_array($_SESSION['login'], $GLOBALS['balanceCanChangeAdmins'])) {
?>
<form action="." method="post">
Изменить счет пользователя
<table cellspacing="2" cellpadding="2" border="0">
<tr>
<td>на сумму(руб):</td>
<td><input type="text" name="val"></td>
</tr>
<tr>
<td>комментарий (для пользователя)</td>
示例14: zin
echo $prj['thread_id'];
?>
" class="blue">
<?php
echo $prj['comm_count'] ? "<b>Комментарии (" . zin($prj['comm_count']) . ")</b>" : "Комментарии (" . zin($prj['comm_count']) . ")";
?>
</a>]</b>
</div><?php
} else {
?>
<div align="right" style="margin-top: 5px;"><b>[<a href="/projects/?pid=<?php
echo $prj['id'];
?>
" class="blue">
<?php
echo $prj['offers_count'] ? "<b>Комментарии (" . zin($prj['offers_count']) . ")</b>" : "Комментарии (" . zin($prj['offers_count']) . ")";
?>
</a>]</b>
</div><?php
}
?>
</td>
<td width="67" align="center" class="qp"><?php
if ($prj['cost'] > 0) {
?>
<strong><?php
echo CurToChar($prj['cost'], $prj['currency']);
?>
</strong><?php
} else {
?>
示例15: zin
"><?php
echo zin($frl['se']);
?>
</a></span><br />
<span class="review-type">-</span><span class="review-minus"><a href="/users/<?php
echo $frl['login'];
?>
/opinions/?from=users&sort=3&f=<?php
echo stat_collector::REFID_CATALOG;
?>
&stamp=<?php
echo $_SESSION['stamp'];
echo $kw_param;
?>
"><?php
echo zin($frl['sl']);
?>
</a></span>
<?php
echo seo_end();
?>
</td>
<td style="width:65px;"><?php
echo view_cost2($frl['frl_cost_hour'], '', '', true, $frl['frl_cost_type_hour']);
?>
</td>
<td class="price_prj" style="width:70px;"><?php
if ($prof_type) {
echo view_cost2($frl['cost_1000'], '', '', true, $frl['cost_type']);
} else {
echo view_cost2($frl['cost_from'], 'от', '', true, $frl['cost_type']);