المشاركة الأصلية كتبت بواسطة: عبدالاله الهذلي الادارة أذا أمكنتفضل الكود بعد اضافة الكود البرمجي للإداريين المتصلين عدلته بشكل سريع ولم اختبره
مثلا بـ الجانب الأيمن [صورة للعضوية ] ومثلا بـ النصف [اسم الأداري ]
وتحت اسمه [اسم المجموعة الخاصة به مثلا [مراقب عام ] او [مدير المنتدى ]
CODE
{if {$_CONF['info_row']['active_static']}}
<ul class="sidebar">
<li class="tcat">
<span>الأداري المتصل الأن</span>
</li>
</ul>
<div class="row_sidebar">
<?php
// Get all admin group id = 1
$forum_team_query = $PowerBB->DB->sql_query("SELECT * FROM " . $PowerBB->table['member'] . " WHERE usergroup='1' or usergroup='2' or usergroup='8' ");
while ($forum_team = $PowerBB->DB->sql_fetch_array($forum_team_query))
{
// Get admin Online
$OnlineArr = array();
$OnlineArr['where'] = array('user_id',$forum_team['id']);
$OnlineList = $PowerBB->core->GetInfo($OnlineArr,'online');
if($OnlineList)
{
?>
<ul class="whatis_new">
<li class="last_posts" style="padding-bottom: 10px;margin-bottom: 10px;">
<ul class="PBBList_reset">
{if {$_CONF['info_row']['allow_avatar']}}
<li class="Photo_lastPoster" style="display:inline-block; margin-top:-3px; padding:2px; width: 32px; height: 32px; -webkit-border-radius: 4px; -moz-border-radius: 4px; -khtml-border-radius: 4px; border-radius: 4px;">
<a href="index.php?page=profile&show=1&id=<?php echo $forum_team['id'];?>">
{if {$lastPostsList['avater_path']} != ''}
<?php
if (@!strstr($forum_team['avater_path'],'http')
or @!strstr($forum_team['avater_path'],'www.'))
{
if (@strstr($forum_team['avater_path'],'download/avatar/')
or @strstr($forum_team['avater_path'],'look/images/avatar/'))
{
$forum_team['avater_path'] = $PowerBB->_CONF['template']['ForumAdress'].$forum_team['avater_path'];
$forum_team['avater_path'] = str_replace($PowerBB->_CONF['template']['ForumAdress'].$PowerBB->_CONF['template']['ForumAdress'], $PowerBB->_CONF['template']['ForumAdress'], $forum_team['avater_path']);
}
}
if ($PowerBB->functions->GetServerProtocol() == 'https://')
{
$https_ = "https://".$PowerBB->_SERVER['HTTP_HOST'];
$httpswww_ = "https://www.".$PowerBB->_SERVER['HTTP_HOST'];
$http_ = "http://".$PowerBB->_SERVER['HTTP_HOST'];
$http_www_ = "http://www.".$PowerBB->_SERVER['HTTP_HOST'];
$forum_team['avater_path'] = str_replace($http_, $https_, $forum_team['avater_path']);
$forum_team['avater_path'] = @str_ireplace($http_, $https_, $forum_team['avater_path']);
$forum_team['avater_path'] = str_replace($http_www_, $httpswww_, $forum_team['avater_path']);
$forum_team['avater_path'] = @str_ireplace($http_www_, $httpswww_, $forum_team['avater_path']);
}
?>
<span class="brd0" style="width: 32px; height: 32px; background-image: url({$lastPostsList['avater_path']});width: 32px; height: 32px; background-position: center; background-repeat: no-repeat; background-size: 32px; display: inline-block; vertical-align: middle;"></span>
{else}
<span class="brd0" style="background-image: url(<?php echo $PowerBB->_CONF['template']['ForumAdress'].$PowerBB->_CONF['template']['image_path'];?>/{$_CONF['info_row']['default_avatar']}); width: 32px; height: 32px; background-position: center; background-repeat: no-repeat; background-size: 32px; display: inline-block; vertical-align: middle;"></span>
{/if}
</a>
</li>
{/if}
<li class="last_subjectid" style="position:relative; vertical-align:middle; margin-top: -2px; display:inline-block;">
<a href="index.php?page=profile&show=1&id=<?php echo $forum_team['id'];?>">
<?php
// اسم العضو
echo $forum_team['username_style_cache'];
?>
</a>
<div class="last_time_post">
<span class="last_time_ago"><?php
// لقب العضو
echo $forum_team['user_title']; ?></span>
</div>
</li>
</ul>
</li>
</ul>
</div>
<?php
}
else
{
echo "لا يوجد إداري متصل حاليا ..";
}
}
?>
{/if}
<div style="clear: both;"></div>
<div style="clear: both;"></div>