<div id="tooltip" onclick="hideToolTip()" style="text-align:center; background-color: #FFFFFF; border: 1px dotted; text-align: {$default_left}; position:absolute; display:none; padding:5px;"></div>
{literal}
<script type="text/javascript">
$(function() {
$('#tool_tip_4 *').tooltip();
});
</script>
{/literal}
<div id="forum_table_div2">
<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr>
	<td>
	<table cellpadding="0" cellspacing="0" width="100%" border="0">
		<tr class="table_header">
			<td height="27" valign="middle" align="left" style="padding-left: 13px; padding-right: 13px;" class="index_quick_search"><b>{$lang.forum.message}</b></td>
			<td width="130" height="27" valign="middle" align="left" style="padding-left: 13px; padding-right: 13px;" class="index_quick_search"><b>{$lang.forum.author}</b></td>
			<td height="27" valign="middle" align="left" style="width:100; padding-left: 13px; padding-right: 13px;" class="index_quick_search"><b>{$lang.forum.posting_date}</b></td>			
			<td height="27" valign="middle" align="centr" style="width:70; padding-left: 13px; padding-right: 13px;" class="index_quick_search"><b>{$lang.forum.status_ban}</b></td>			
			<td height="27" valign="middle" align="right" style="padding-left: 13px; padding-right: 13px;" class="index_quick_search"><b>{$lang.button.action}</b></td>
		</tr>
		{section name=f loop=$forum}
		<tr {if $smarty.section.f.index mod 2 eq 1}class="table_row even"{else}class="table_row odd"{/if}>
			<td valign="top" style="padding-left: 13px;" align="left">
				<table cellpadding="0" cellspacing="0" width="100%">
				<tr>
					<td align="left" class="main_header_text" style="padding-top: 7px;padding-left:0px;">{$forum[f].subject}</td>
				</tr>
				<tr>
					<td align="left" style="padding-bottom: 10px; padding-top: 7px; padding-right: 7px;padding-left:0px;"><div class="wysiwyg_content">{$forum[f].message}</div></td>
				</tr>
				</table>
			</td>
			<td valign="top" align="left" style="padding-left: 13px;">
				<table cellpadding="0" cellspacing="0">
				<tr>
					<td style="padding-top: 7px; padding-right: 7px;padding-left:0px;">{if $forum[f].poster_profile eq 1}<a href="admin_users.php?sel=edituser&editpage=1&page=1&id={$forum[f].id_user}" target="_blank">{/if}<b>{$forum[f].login_user}</b>{if $forum[f].poster_profile eq 1}</a>{/if}</td>
				</tr>
				</table>
			</td>
			<td valign="top" align="left" style="padding-top: 7px; padding-right: 7px;padding-left: 13px;">{$forum[f].date}</td>
			<td valign="top" align="center" style="padding-top: 7px; padding-right: 7px;padding-left: 13px;">
			{if $forum[f].poster_profile ne 0}
				{if $forum[f].is_banned eq 0}
					<div class="fl" style="width:10px;float:right;">&nbsp;</div>
					<div class="fl" style="width:10px;float:right;">&nbsp;</div>
					<div class="fl" style="width:10px;float:right;">&nbsp;</div>
					<div class="block_action fr" style="display: none;">
						<div class="action_edit" style="display: block;">
							<img width="16" alt="" src="{$site_root}{$template_root}/images/user_inactive.png" onmouseout="javascript:hideToolTip();" onmouseover="javascript: showToolTip(event,'{$lang.button.make_inactive}');return false" onclick="Save2('ban', '{$forum[f].id_user}', '{$data.subcategory_id}', '{$data.category_id}');">
						</div>
					</div>
				{elseif $forum[f].is_banned eq 1}
					<div class="fl" style="width:10px;float:right;">&nbsp;</div>
					<div class="fl" style="width:10px;float:right;">&nbsp;</div>
					<div class="fl" style="width:10px;float:right;">&nbsp;</div>
					<div class="block_action fr" style="display: none;">
						<div class="action_edit" style="display: block;">
							<img width="16" alt="" src="{$site_root}{$template_root}/images/user_active.png" onmouseout="javascript:hideToolTip();" onmouseover="javascript: showToolTip(event,'{$lang.button.make_active}');return false" onclick="Save2('unban', '{$forum[f].id_user}', '{$data.subcategory_id}', '{$data.category_id}');">
						</div>
					</div>
				{/if}
			{/if}
				<span>&nbsp;</span></a>
				</td>{*document.location.href='admin_forum.php?sel=ban&id_user={$forum[f].id_user}&id_subcategory={$data.subcategory_id}&id_category={$data.category_id}';*}
			<td style="width: 120px;" align="right" valign="top">
				<table cellpadding="0" cellspacing="0" width="100%" border="0">
					<tr>
						<td height="20">&nbsp;</td>
						<td style="padding-top: 7px; padding-right: 7px; padding-bottom: 10px;" align="right">
							<div class="block_action fr" style="display: none;">
								<div class="action_edit" style="display: block;float:left;">
									<img height="16" alt="" src="{$site_root}{$template_root}/images/edit.png" onmouseout="javascript:hideToolTip();" onmouseover="javascript: showToolTip(event,'{$lang.button.edit}');return false" onclick="document.location.href='{$file_name}?sel=edit_post&id_post={$forum[f].id}&type={$type}'">
								</div>
								<div style="width:10px;" class="fl">&nbsp;</div>
								<div class="action_del" style="display: block;float:left;">
									<img height="16" alt="" src="{$site_root}{$template_root}/images/photo_delete.png" onmouseout="javascript:hideToolTip();" onmouseover="javascript: showToolTip(event,'{$lang.button.delete}');return false" onclick="{literal} if (confirm('{/literal}{$lang.forum.del_confirm|escape:javascript}{literal}')) { document.location.href='{/literal}{$file_name}?sel=delete_post&id_post={$forum[f].id}{literal}'}; return false;{/literal}">
								</div>
							</div>						
						</td>
					</tr>
				</table>
			</td>
		</tr>
		<tr bgcolor="#f2f2f2">
			<td colspan="2" height="2"></td>
		</tr>
		{sectionelse}
		<tr height="40">
			<td class="main_error_text" align="left" colspan="5">{$lang.interests_spr.empty}</td>
		</tr>
		{/section}
		<tr class="table_header"><td colspan="5">&nbsp;</td></tr>
	</table>
	</td>
</tr>
{if $links}
<tr>
	<td>
	<div style="margin-left: 0px; padding-top: 15px;" >
	{foreach item=item from=$links}
		<span style="padding-right: 15px;"><a href="{$item.link}" {if $item.selected eq '1'} class="text_head"{/if}>{$item.name}</a></span>
	{/foreach}
	</div>
	</td>
</tr>
{/if}
</table>
</div>
<script type="text/javascript">
{literal}
		function showToolTip(e,text){
			if(document.all)e = event;
			var obj = document.getElementById('tooltip');
			obj.innerHTML = text;
			obj.style.display = 'block';
			var st = Math.max(document.body.scrollTop,document.documentElement.scrollTop);
			if(navigator.userAgent.toLowerCase().indexOf('safari')>=0)st=0;
			var leftPos = e.clientX - $('#tooltip').width()-10;
			if(leftPos<0)leftPos = 0;
			obj.style.left = leftPos + 'px';
			obj.style.top = e.clientY - obj.offsetHeight -10 + st + 'px';
		}
		function hideToolTip(){
			document.getElementById('tooltip').style.display = 'none';
		}
{/literal}		
</script>