
{include file="../head.tpl"}
{if count($errors)}
<table width="100%" border="0" cellpadding="5" cellspacing="1" class="tableborder">
	<tr>
		<td colspan="2" class="secondrow">
			{foreach from=$errors item=error}
				<li>{$error}</li>
			{/foreach}
	  </td>
	</tr>
</table>
{/if}
<form action="forum.php?action=save&amp;what=permissions" method="post">
	<input type="hidden" name="f_id" value="{$smarty.get.f_id}" />
	<input type="hidden" name="g_id" value="{$smarty.request.g_id}" />
	<table width="100%" border="0" cellpadding="5" cellspacing="1" class="tableborder">
	<tr>
		<th colspan="2" class="header">{$langadmin.forum_forum_permissions}</th>
	</tr>
	<tr>
		<td width="60%" valign="top" class="firstrow">{$langadmin.forum_permission_can_see}:</td>
		<td class="secondrow">
			<input type="radio" name="can_see" value="1" {if $permissions[0] == 1 || $permissions[0] == ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_see" value="0" {if $permissions[0] == 0 && $permissions[0] != ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_see_topic}:</td>
		<td class="secondrow">
			<input type="radio" name="can_see_topic" value="1" {if $permissions[1] == 1 || $permissions[1] == ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_see_topic" value="0" {if $permissions[1] == 0 && $permissions[1] != ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_download_attachment}:</td>
		<td class="secondrow">
			<input type="radio" name="can_download_attachment" value="1" {if $permissions[4] == 1 || $permissions[4] == ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_download_attachment" value="0" {if $permissions[4] == 0 && $permissions[4] != ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	<tr>
		<th colspan="2" class="header">{$langadmin.forum_post_permissions}</th>
	</tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_create_topic}:</td>
		<td class="secondrow">
			<input type="radio" name="can_create_topic" value="1" {if $permissions[5] == 1 || $permissions[5] == ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_create_topic" value="0" {if $permissions[5] == 0 && $permissions[5] != ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_reply_own_topic}:</td>
		<td class="secondrow">
			<input type="radio" name="can_reply_own_topic" value="1" {if $permissions[6] == 1 || $permissions[6] == ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_reply_own_topic" value="0" {if $permissions[6] == 0 && $permissions[6] != ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_reply_other_topic}:</td>
		<td class="secondrow">
			<input type="radio" name="can_reply_other_topic" value="1" {if $permissions[7] == 1 || $permissions[7] == ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_reply_other_topic" value="0" {if $permissions[7] == 0 && $permissions[7] != ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>

{if $smarty.get.g_id!=2}

	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_upload_attachment}:</td>
		<td class="secondrow">
			<input type="radio" name="can_upload_attachment" value="1" {if $permissions[8] == 1 || $permissions[8] == ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_upload_attachment" value="0" {if $permissions[8] == 0 && $permissions[8] != ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>

	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_rate_topic}:</td>
		<td class="secondrow">
			<input type="radio" name="can_rate_topic" value="1" {if $permissions[9] == 1 || $permissions[9] == ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_rate_topic" value="0" {if $permissions[9] == 0 && $permissions[9] != ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>



	<tr>
		<th colspan="2" class="header">{$langadmin.forum_post_topic_permissions}</th>
	</tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_edit_own_post}:</td>
		<td class="secondrow">
			<input type="radio" name="can_edit_own_post" value="1" {if $permissions[10] == 1 || $permissions[10] == ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_edit_own_post" value="0" {if $permissions[10] == 0 && $permissions[10] != ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_delete_own_post}:</td>
		<td class="secondrow">
			<input type="radio" name="can_delete_own_post" value="1" {if $permissions[11] == 1 && $permissions[11] != ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_delete_own_post" value="0" {if $permissions[11] == 0 || $permissions[11] == ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	<tr>
	  <td valign="top" class="firstrow">{$langadmin.forum_permission_can_edit_other_post}:</td>
	  <td class="secondrow">
	  <input type="radio" name="can_edit_other_post" value="1" {if $permissions[16] == 1 && $permissions[16] != ""}checked="checked"{/if} /> {$langadmin.yes}
	<input type="radio" name="can_edit_other_post" value="0" {if $permissions[16] == 0 || $permissions[16] == ""}checked="checked"{/if} /> {$langadmin.no}

	  </td>
    </tr>
	<tr>
	  <td valign="top" class="firstrow">{$langadmin.forum_permission_can_delete_other_post}:</td>
	  <td class="secondrow">
	  <input type="radio" name="can_delete_other_post" value="1" {if $permissions[15] == 1 && $permissions[15] != ""}checked="checked"{/if} /> {$langadmin.yes}
	<input type="radio" name="can_delete_other_post" value="0" {if $permissions[15] == 0 || $permissions[15] == ""}checked="checked"{/if} /> {$langadmin.no}

	  </td>
    </tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_move_own_topic}:</td>
		<td class="secondrow">
			<input type="radio" name="can_move_own_topic" value="1" {if $permissions[12] == 1 && $permissions[12] != ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_move_own_topic" value="0" {if $permissions[12] == 0 || $permissions[12] == ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_close_open_own_topic}:</td>
		<td class="secondrow">
			<input type="radio" name="can_close_open_own_topic" value="1" {if $permissions[13] == 1 && $permissions[13] != ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_close_open_own_topic" value="0" {if $permissions[13] == 0 || $permissions[13] == ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_delete_own_topic}:</td>
		<td class="secondrow">
			<input type="radio" name="can_delete_own_topic" value="1" {if $permissions[14] == 1 && $permissions[14] != ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_delete_own_topic" value="0" {if $permissions[14] == 0 || $permissions[14] == ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>

	
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_opentopic}:</td>
		<td class="secondrow">
			<input type="radio" name="can_open_topic" value="1" {if $permissions[17] == 1 && $permissions[17] != ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_open_topic" value="0" {if $permissions[17] == 0 || $permissions[17] == ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	
		<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_closetopic}
		  :</td>
		<td class="secondrow">
			<input type="radio" name="can_close_topic" value="1" {if $permissions[18] == 1 && $permissions[18] != ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_close_topic" value="0" {if $permissions[18] == 0 || $permissions[18] == ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	
	<tr>
	<th colspan="2" class="header">{$langadmin.forum_permission_modificator}</th>
	</tr>
	
	<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_changetype}:</td>
		<td class="secondrow">
			<input type="radio" name="can_change_topic_type" value="1" {if $permissions[19] == 1 && $permissions[19] != ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_change_topic_type" value="0" {if $permissions[19] == 0 || $permissions[19] == ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	
	
	
		<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_moveother}:</td>
		<td class="secondrow">
			<input type="radio" name="can_move_topic" value="1" {if $permissions[20] == 1 && $permissions[20] != ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_move_topic" value="0" {if $permissions[20] == 0 || $permissions[20] == ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
	
		<tr>
		<td valign="top" class="firstrow">{$langadmin.forum_permission_can_deltopicsother}:</td>
		<td class="secondrow">
			<input type="radio" name="can_delete_topic" value="1" {if $permissions[21] == 1 && $permissions[21] != ""}checked="checked"{/if} /> {$langadmin.yes}
			<input type="radio" name="can_delete_topic" value="0" {if $permissions[21] == 0 || $permissions[21] == ""}checked="checked"{/if} /> {$langadmin.no}
		</td>
	</tr>
{/if}

	
	<tr>
		<th colspan="2" class="selectrow">
			<input name="settoall" type="checkbox" id="settoall" value="1">
			{$langadmin.setperms_forall_kateges}<br>
			<input class="button" type="submit" value="{$langadmin.edit}" />
	  </th>
	</tr>
</table>
</form>
{include file="../foot.tpl"}
