Перейти до змісту
Домент ipb-board.ru продається.

Исправляем ошибку с отображением списка пользователей, просматривающих тему

Рекомендовані відповіді

Опубліковано
  • Адміністратор

В шаблоне forumIndexTemplate находим:

<if test="showactiveusers:|:!$this->settings['no_au_forum']">		<div id='forum_active_users' class='active_users stats_list'>				<h4 class='statistics_head'>{parse exp[b][/b]ression="sprintf( $this->lang->words['active_users_titlef'], ($active_user_data['members'] + $active_user_data['guests'] + $active_user_data['anon'] ) )"}</h4>				<p class='statistics_brief'>{parse exp[b][/b]ression="sprintf( $this->lang->words['active_users_detail'], $active_user_data['members'], $active_user_data['guests'], $active_user_data['anon'] )"}</p>				<br />				<ul class='ipsList_inline'>						<if test="hasactiveusers:|:is_array( $active_user_data['names'] ) AND count( $active_user_data['names'] )">								<foreach loop="activeusers:$active_user_data['names'] as $p => $r">						<li>{$r['p_start']}<if test="aumemberid:|:$r['id']"><a href='{parse url="showuser={$r['id']}" seotitle="{$r['seo']}" template="showuser" base="public"}' title='{$r['p_title']}'></if>{$r['name']}<if test="aumidend:|:$r['id']"></a></if>{$r['p_end']}<if test="auaddcomma:|:$p + 1 != count( $active_user_data['names'] )">,</if></li>								</foreach>						</if>				</ul>		</div></if>

И заменяем на:

<if test="showactiveusers:|:!$this->settings['no_au_forum'] && $this->memberData['gbw_view_online_lists']">						<div id='forum_active_users' class='active_users stats_list'>								<h4 class='statistics_head'>{parse exp[b][/b]ression="sprintf( $this->lang->words['active_users_titlef'], $active_user_data['stats']['total'] )"}</h4>								<p class='statistics_brief'>{parse exp[b][/b]ression="sprintf( $this->lang->words['active_users_detail'], $active_user_data['stats']['members'], $active_user_data['stats']['guests'], $active_user_data['stats']['anon'] )"}</p>								<br />								<ul class='ipsList_inline'>										<if test="hasactiveusers:|:is_array( $active_user_data['names'] ) AND count( $active_user_data['names'] )">												{parse exp[b][/b]ression="implode( ', ', $active_user_data['names'] )"}										</if>								</ul>						</div>				</if>

Далее, в шаблоне topicViewTemplate находим:

!-- ACTIVE USERS --><if test="topicActiveUsers:|:is_array( $displayData['active_users'] ) AND count( $displayData['active_users'] )">		<div id='topic_stats' class='statistics clear clearfix'>				<div id='topic_active_users' class='active_users'>						<h4 class='statistics_head'>{parse exp[b][/b]ression="sprintf( $this->lang->words['active_users_title'], ($displayData['active_users']['members'] + $displayData['active_users']['guests'] + $displayData['active_users']['anon'] ) )"}</h4>						<p class='statistics_brief desc'>{parse exp[b][/b]ression="sprintf( $this->lang->words['active_users_detail'], $displayData['active_users']['members'], $displayData['active_users']['guests'], $displayData['active_users']['anon'] )"}</p>						<if test="auNames:|:is_array( $displayData['active_users']['names'] ) AND count( $displayData['active_users']['names'] )">								<br />								<ul class='ipsList_inline'>										<foreach loop="active_users:$displayData['active_users']['names'] as $p => $r">								<li>{$r['p_start']}<if test="auId:|:$r['id']"><a href='{parse url="showuser={$r['id']}" seotitle="{$r['seo']}" template="showuser" base="public"}' title='{$r['p_title']}'></if>{$r['name']}<if test="auEndId:|:$r['id']"></a></if>{$r['p_end']}<if test="lastActiveUser:|:$p + 1 != count( $displayData['active_users']['names'] )">,</if></li>										</foreach>								</ul>						</if>				</div>		</div></if>

И заменяем на:

<!-- ACTIVE USERS --><if test="topicActiveUsers:|:is_array( $displayData['active_users'] ) AND count( $displayData['active_users'] )">		<div id='topic_stats' class='statistics clear clearfix'>				<div id='topic_active_users' class='active_users'>						<h4 class='statistics_head'>{parse exp[b][/b]ression="sprintf( $this->lang->words['active_users_title'], $displayData['active_users']['stats']['total'] )"}</h4>						<p class='statistics_brief desc'>{parse exp[b][/b]ression="sprintf( $this->lang->words['active_users_detail'], $displayData['active_users']['stats']['members'], $displayData['active_users']['stats']['guests'], $displayData['active_users']['stats']['anon'] )"}</p>						<if test="auNames:|:is_array( $displayData['active_users']['names'] ) AND count( $displayData['active_users']['names'] )">								<br />								<ul class='ipsList_inline'>										{parse exp[b][/b]ression="implode( ', ', $displayData['active_users']['names'] )"}								</ul>						</if>				</div>		</div></if>

 

Для публікації повідомлень створіть обліковий запис або авторизуйтесь