Перейти к содержимому


Информация статьи

  • Дабавлена: 08 фев 2012 01:29
  • Просмотров: 995
 


* * * * *
0 Рейтинг

Добавляем аватары в Чат

Написано ๖ۣۣۜDesperate™ 08 фев 2012 01:29
Как добавить аватар в чат до версии 1.2.7(тут они уже в настройке идут)

Открываем Внешний вид - Ваш Стиль - Шаблоны - skin_shoutbox - shout_row

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

<if test="$ajax==false"><tr class='row2' id='shout-{$d['_archive']}row-{$d['s_id']}'></if>
	    <td align='right' valign='top' nowrap='nowrap' width='1%'>
					    <if test="$d['member_id'] && $this->registry->getClass('shoutboxLibrary')->moderator"><a href='#member{$d['member_id']}' onclick='return ipshoutbox.shoutAjax.modOptsLoadMember({$d['member_id']})' title='{$this->lang->words['mmenu_load_mod_opts']}'>{parse replacement="user_edit_icon"}</a> </if>
					    <if test="$d['member_id']">
									    <a href='{parse url="showuser={$d['member_id']}" template="showuser" seotitle="{$d['members_seo_name']}" base="public"}' title='{$d['members_display_name']}'>[/size][/size][/color][/size]
[size=5][color=#000080][size=3][size=4]<php>
$this->DB->build( array( 'select' => 'avatar_location, avatar_type, pp_thumb_width, pp_thumb_height, pp_thumb_photo', 'from' => 'profile_portal', 'where' => 'pp_member_id='.$d[member_id].'' ) );
$this->DB->execute();[/size][/size][/color][/size]
[size=5][color=#000080][size=3][size=4]$memberthing = $this->DB->fetch();
</php>[/size][/size][/color][/size]
[size=5][color=#000080][size=3][size=4]<if test="$memberthing['pp_thumb_photo'] == '' && $memberthing['avatar_location'] != '' ">
	    <if test="$memberthing['avatar_type'] != 'url'">
					    <img src='{$this->settings['board_url']}<if test="$memberthing['avatar_type'] == 'upload'">/uploads/<else />/public/style_avatars/</if>{$memberthing['avatar_location']}' alt="{$r['starter_name']}{$this->lang->words['users_photo']}" style='max-width:auto; max-height:20px;' class='photo' />
	    <else />
					    <img src='{$memberthing['avatar_location']}' alt="{$r['starter_name']}{$this->lang->words['users_photo']}" style='50px; max-height:20px;' class='photo' />
	    </if>
	    <else />
					    <if test="$memberthing['pp_thumb_photo'] == ''">
					    <img src='{$this->settings['img_url']}/profile/default_thumb.png' alt="{$r['starter_name']}{$this->lang->words['users_photo']}" style='max-width:20px; max-height:20px;' class='photo' />
					    <else />
					    <img src='{$this->settings['board_url']}/uploads/{$memberthing['pp_thumb_photo']}' alt="{$r['starter_name']}{$this->lang->words['users_photo']}" style='max-width:auto; max-height:20px;' class='photo' />
					    </if>
	    </if>[/size][/size][/color][/size]
[size=5][color=#000080][size=3][size=4]{$d['_members_display_name']}</a>{parse template="user_popup" group="global" params="$d['s_mid'], $d['members_seo_name']"}
					    <else />
									    <abbr title="{$d['members_display_name']}">{$d['_members_display_name']}</abbr>
					    </if>
					    :
	    </td>
	    <td  width='99%'>
					    <span class='right shoutbox_time' title='{$d['_date']}'>({$d['s_date']})<if test="$can_edit || ($this->registry->getClass('shoutboxLibrary')->moderator && $this->registry->getClass('shoutboxLibrary')->checkModeratorPerm('edit_shouts', true))"> <a href='{parse url="app=shoutbox" seotitle="false" base="public"}#edit{$d['s_id']}' onclick='return ipshoutbox.shoutAjax.editShout({$d['s_id']})' title='{$this->lang->words['mod_opt_edit']}'>{parse replacement="edit_post_icon"}</a></if><if test="$this->registry->getClass('shoutboxLibrary')->moderator"> <a href='{parse url="app=shoutbox" seotitle="false" base="public"}#shout{$d['s_id']}' onclick='return ipshoutbox.shoutAjax.modOptsLoadShout({$d['s_id']})' title='{$this->lang->words['mmenu_load_mod_opts']}'>{parse replacement="edit_folder"}</a></if></span>
					    <if test="$d['_ignored'] == 1">
									    <span id='unhide_shout_{$d['s_id']}' class='shoutbox_time'>{$this->lang->words['ignored_shouter']} <a href='#shout{$d['s_id']}' onclick='return ipshoutbox.showHiddenShout({$d['s_id']})' title='{$this->lang->words['ignored_shouter_view']}'>{$this->lang->words['ignored_shouter_view']}</a></span>
									    <span id='hidden_shout_{$d['s_id']}' style='display:none'>{$d['s_message']}</span>
					    <else />[/size][/size][/color][/size]
[size=5][color=#000080][size=3][size=4]				  {$d['s_message']}
					    </if>
	    </td>
<if test="$ajax==false"></tr></if>
  • 0

Powered by Tutorials 1.5.0 © 2016, by Michael McCune