个人中心最近访客时间显示分行,u/themes/default/user_home.htm
- <!--
- EOT;
- if(empty($space[visits])){
- $space[visits]="0";
- }print <<<EOT
- -->
- <h5 class="h5 mb5"><span class="fr gray">累积访客($space[visits])</span><strong class="mr10">最近访客</strong></h5>
- <div class="ulB mb20 cc">
- <!--
- EOT;
- if (empty($latestVisits)) {
- print <<<EOT
- -->
- <div>暂无访客,<a href="u.php?a=friend&type=find">加几个好友</a>吧!</div>
- <!--
- EOT;
- } else {
- foreach ($latestVisits as $visitor) {
- if (is_array($visitor)) {
- $dateString = get_date($visitor['timestamp'], 'Y-m-d H:i');
- print <<<EOT
- -->
- <li style="margin:5px 18px 0 1px;">
- <a href="{$db_userurl}{$visitor[uid]}" class="i _cardshow" target="_blank" data-card-url="pw_ajax.php?action=smallcard&type=showcard&uid={$visitor[uid]}" data-card-key="{$visitor['username']}"><img src="{$visitor[icon]}" width="48" height="48" /></a>
- <p class="n"><a href="{$db_userurl}{$visitor[uid]}" alt="{$visitor[username]}" title="{$visitor[username]}" class=" _cardshow" target="_blank" data-card-url="pw_ajax.php?action=smallcard&type=showcard&uid={$visitor[uid]}" data-card-key="{$visitor['username']}">{$visitor[username]}</a></p>
- <p class="t gray"><span title="$dateString">{$visitor[visittime]}</span></p>
- </li>
改为:
$dateString2 = get_date($visitor['timestamp'], 'y.m.d');/*2019.3.5添加以替换下面的{$visitor[visittime]}*/
print <<<EOT
-->
<li style="margin:5px 18px 0 1px;">
<a href="{$db_userurl}{$visitor[uid]}" class="i _cardshow" target="_blank" data-card-url="pw_ajax.php?action=smallcard&type=showcard&uid={$visitor[uid]}" data-card-key="{$visitor['username']}"><img src="{$visitor[icon]}" width="48" height="48" /></a>
<p class="n"><a href="{$db_userurl}{$visitor[uid]}" alt="{$visitor[username]}" title="{$visitor[username]}" class=" _cardshow" target="_blank" data-card-url="pw_ajax.php?action=smallcard&type=showcard&uid={$visitor[uid]}" data-card-key="{$visitor['username']}">{$visitor[username]}</a></p>
<p class="t gray"><span title="$dateString">
{$dateString2}</span></p>
</li>