<?php
if (!defined('_GNUBOARD_')) exit; // 개별 Page 접근 불가

// input의 name을 wset[배열키] 형태로 등록
// Mobile 설정값은 동일 배열키에 배열변수만 wmset으로 지정 → wmset[배열키]

if(!$wset['mode']) $wset['mode'] = 'np';

?>

<div class="tbl_head01 tbl_wrap">
	<table>
	<caption>Widget Settings</caption>
	<colgroup>
		<col class="grid_2">
		<col>
	</colgroup>
	<thead>
	<tr>
		<th scope="col">Cateogry</th>
		<th scope="col">Set</th>
	</tr>
	</thead>
	<tbody>
	<tr>
		<td align="center">Extract Number</td>
		<td>
			<input type="text" name="wset[rows]" value="<?php echo $wset['rows']; ?>" class="frm_input" size="3"> 개 - PC
			&nbsp;
			<input type="text" name="wmset[rows]" value="<?php echo $wmset['rows']; ?>" class="frm_input" size="3"> 개 - Mobile
			&nbsp;
			<input type="text" name="wset[page]" value="<?php echo $wset['page'];?>" size="3" class="frm_input"> Page Source
		</td>
	</tr>
	<tr>
		<td align="center">Extraction Mode</td>
		<td>
			<select name="wset[mode]">
				<?php echo apms_member_options($wset['mode']);?>
			</select>
			&nbsp;
			<label>
				<input type="checkbox" name="wset[cnt]" value="1"<?php echo get_checked('1', $wset['cnt']); ?>> Point Stats
			</label>
		</td>
	</tr>
	<tr>
		<td align="center">Excluded Ratings</td>
		<td>
			<?php echo help('제외 회원등급을 콤마(,)로 구분해서 복수 등록 가능 - 일부 모드 적용안됨');?>
			<input type="text" name="wset[ex_grade]" value="<?php echo $wset['ex_grade']; ?>" size="60" class="frm_input">
		</td>
	</tr>
	<tr>
		<td align="center">Excluded Members</td>
		<td>
			<?php echo help('제외 You can register multiple member IDs separated by a comma (,).');?>
			<input type="text" name="wset[ex_mb]" value="<?php echo $wset['ex_mb']; ?>" size="60" class="frm_input">
		</td>
	</tr>
	<tr>
		<td align="center">Attendance Board</td>
		<td>
			<?php echo help('출석부 보드아이디 1개만 등록 가능');?>
			<input type="text" name="wset[bo_table]" value="<?php echo $wset['bo_table']; ?>" size="60" class="frm_input">
			&nbsp;
		</td>
	</tr>
	<tr>
		<td align="center">Extraction Members</td>
		<td>
			<?php echo help('You can register multiple board IDs by separating them with comma (,).');?>
			<input type="text" name="wset[bo_list]" value="<?php echo $wset['bo_list']; ?>" size="60" class="frm_input">
			&nbsp;
		</td>
	</tr>
	<tr>
		<td align="center">Extraction Groups</td>
		<td>
			<?php echo help('You can register multiple group IDs separated by a comma (,).');?>
			<input type="text" name="wset[gr_list]" value="<?php echo $wset['gr_list']; ?>" size="60" class="frm_input">
		</td>
	</tr>
	<tr>
		<td align="center">Exclusion Settings</td>
		<td>
			<label><input type="checkbox" name="wset[except]" value="1"<?php echo get_checked('1', $wset['except']);?>> Exclud Specific Boards/Groups</label>
		</td>
	</tr>
	<tr>
		<td align="center">Icon</td>
		<td>
			<input type="text" name="wset[icon]" id="fcon" value="<?php echo ($wset['icon']);?>" size="30" class="frm_input"> 
			<a href="<?php echo G5_BBS_URL;?>/icon.php?fid=fcon" class="btn_frmline win_scrap">Select Icon</a>
			&nbsp;
			<select name="wset[icolor]">
				<option value=""<?php echo get_selected('', $wset['icolor']); ?>>Default Color</option>
				<?php echo apms_color_options($wset['icolor']);?>
			</select>
		</td>
	</tr>
	<tr>
		<td align="center">Set Date Range</td>
		<td>
			<select name="wset[term]">
				<?php echo apms_term_options($wset['term']);?>
			</select>
			&nbsp;
			<input type="text" name="wset[dayterm]" value="<?php echo $wset['dayterm'];?>" size="3" class="frm_input"> Up to Date
		</td>
	</tr>
	<tr>
		<td align="center">Show Rank</td>
		<td>
			<select name="wset[rank]">
				<option value=""<?php echo get_selected('', $wset['rank']); ?>>Hide Rank</option>
				<?php echo apms_color_options($wset['rank']);?>
			</select>
		</td>
	</tr>
	<tr>
		<td align="center">Enable Cache</td>
		<td>
			<input type="text" name="wset[cache]" value="<?php echo $wset['cache']; ?>" class="frm_input" size="4"> Cache Seconds
		</td>
	</tr>
	</tbody>
	</table>
</div>