<? if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가 ?>

<table border=0 class="admin_head">
<tr>
<th><h2 class="sub_title left">▶ 일반 관리</h2></th>
<td><?=$amina_btn?></td>
</tr>
</table>

<table border=0 class="admin_tbl">
<colgroup>
	<col class="w120">
	<col class="w120">
	<col class="w120">
	<col class="w120">
	<col class="w120">
	<col class="w120">
	<col>
</colgroup>
<tr>
<th>XP측정</th>
<th>XP리셋</th>
<th>설정값</th>
<th>썸네일</th>
<th>글반응</th>
<th>회원사진</th>
<th>&nbsp;</th>
</tr>
<tr>
<td align=center>
	<input type="button" value="측정하기" onclick="amina_win('<?=AMINA_URL?>/recheck.exp.php',700,600,1);" class="btn_red">
</td>
<td align=center>
	<input type="button" value="일괄산출" onclick="amina_win('<?=AMINA_URL?>/reset.exp.php');" class="btn_blue">
</td>
<td align=center>
	<input type="button" value="일괄정리" onclick="amina_win('<?=AMINA_URL?>/reset.set.php');" class="btn_red">
</td>
<td align=center>
	<input type="button" value="일괄삭제" onclick="amina_win('<?=AMINA_URL?>/reset.thumb.php');" class="btn_blue">
</td>
<td align=center>
	<input type="button" value="일괄정리" onclick="amina_win('<?=AMINA_URL?>/reset.response.php');" class="btn_red">
</td>
<td align=center>
	<input type="button" value="일괄정리" onclick="amina_win('<?=AMINA_URL?>/reset.photo.php');" class="btn_blue">
</td>
<td>&nbsp;</td>
</tr>
</table>

<table border=0 class="admin_head">
<tr>
<th><h2 class="sub_title left">▶ 기능 설정 DB 관리</h2></th>
<td>&nbsp;</td>
</tr>
</table>

<table border=0 class="admin_tbl">
<colgroup>
	<col class="w120">
	<col>
	<col class="w60">
	<col class="w60">
	<col class="w60">
	<col class="w60">
</colgroup>
<tr>
<th>게시판 ID</th>
<th>&nbsp;</th>
<th>&nbsp;</th>
<th>&nbsp;</th>
<th>&nbsp;</th>
<th>&nbsp;</th>
</tr>
<? 
	$result = sql_query(" select * from {$g5['amina']} order by bo_table ", false); 
	$i = 0;
	while ($row = sql_fetch_array($result)) { 
		$bg = $i%2 ? '' : ' class="bg_gray"';
		echo "<tr".$bg.">";
		echo "<td>".$row['bo_table']."</td>";
		echo "<td>&nbsp;</td>";
		echo "<td><a href=\"".AMINA_URL."/admin.dashboard.php?loc=func&bo_table=".$row['bo_table']."\">수정</a></td>";
		echo "<td><a href=\"".AMINA_URL."/admin.update.php?loc=ma&type=func&bo_table=".$bo_table."&id=".$row['id']."\">삭제</a></td>";
		echo "<td><a href=\"".G5_BBS_URL."/board.php?bo_table=".$row['bo_table']."\">보기</a></td>";
		echo "<td><a href=\"javascript:amina_win('".AMINA_URL."/admin.copy.php?type=func&id=".$row['id']."');\">복사</a></td>";
		echo "</tr>\n";
		$i++;
	}
?>
</table>

<table border=0 class="admin_head">
<tr>
<th><h2 class="sub_title left">▶ 스킨 설정 DB 관리</h2></th>
<td>&nbsp;</td>
</tr>
</table>

<table border=0 class="admin_tbl">
<colgroup>
	<col class="w80">
	<col class="w120">
	<col class="w160">
	<col>
	<col class="w60">
	<col class="w60">
	<col class="w60">
	<col class="w60">
</colgroup>
<tr>
<th>&nbsp;</th>
<th>게시판 ID</th>
<th>카테고리</th>
<th>&nbsp;</th>
<th>&nbsp;</th>
<th>&nbsp;</th>
<th>&nbsp;</th>
<th>&nbsp;</th>
</tr>
<? 
	$result = sql_query(" select * from {$g5['amina_skin']} order by bo_table, skin_type, sca desc ", false); 
	$i = 0;
	while ($row = sql_fetch_array($result)) { 
		$bg = $i%2 ? '' : ' class="bg_gray"';
		$c_type = $row['sca'] ? $row['sca'] : '전체(공통)';
		if($row['skin_type'] > 1) { //PC
			$s_type = '모바일';
			$l_type = 'm';
			$o_type = '&device=mobile';
		} else {
			$s_type = 'PC';
			$l_type = 'pc';
			$o_type = '';
		}
		echo "<tr".$bg.">";
		echo "<td>".$s_type."</td>";
		echo "<td>".$row['bo_table']."</td>";
		echo "<td>".$c_type."</td>";
		echo "<td>&nbsp;</td>";
		echo "<td><a href=\"".AMINA_URL."/admin.dashboard.php?loc=".$l_type."&bo_table=".$row['bo_table']."&sca=".urlencode($row['sca'])."\">수정</a></td>";
		echo "<td><a href=\"".AMINA_URL."/admin.update.php?loc=ma&type=skin&bo_table=".$row['bo_table']."&id=".$row['id']."\">삭제</a></td>";
		echo "<td><a href=\"".G5_BBS_URL."/board.php?bo_table=".$row['bo_table'].$o_type."\">보기</a></td>";
		echo "<td><a href=\"javascript:amina_win('".AMINA_URL."/admin.copy.php?type=skin&id=".$row['id']."');\">복사</a></td>";
		echo "</tr>\n";
		$i++;
	}
?>
</table>

<table border=0 class="admin_head no_margin">
<tr>
<th> </th>
<td><?=$amina_btn?></td>
</tr>
</table>
