<!--
<?php 

print <<<EOT
-->
<div class="nav4 mb10">
	<ul class="cc">
		<li><a href="$stopic_admin_url&job=stman">專題內容管理</a></li>
		<li class="current"><a href="$stopic_admin_url&job=cgman">專題分類管理</a></li>
		<li><a href="$stopic_admin_url&job=bgman">背景圖片管理</a></li>
	</ul>
</div>
<div class="admin_info mb10">
	<h3 class="h1">功能說明</h3>
	<div class="legend">
		默認分類不可編輯刪除，自定義分類留空提交即可刪除，刪除後原分類下背景圖片可供其他所有分類調用
	</div>
</div>
<form action="$stopic_admin_url&job=$job" method="post" name="">
<input type="hidden" name="action" value="modify">
<h2 class="h1">專題分類管理</h2>
<div class="admin_table mb10">
<table width="100%">
<!-- 
EOT;
//分類循環開始
foreach($categoryLists as $list){
//顯示默認分類
if($list['status'] == 1){

print <<<EOT
 -->
	<tr class="tr1">
		<td class="td2">$list[title]</td>
	</tr>
<!-- 
EOT;
//顯示自定義分類
}else{

print <<<EOT
 -->
	<tr class="tr1">
		<td class="td2"><input name="category_title[$list[id]]" type="text" value="$list[title]" class="input input_wa" /> <a href="javascript:" onclick="isDel('$stopic_admin_url&job=$job&action=delete&categoryid=$list[id]')">刪除</a></td>
	</tr>
<!-- 
EOT;

}
//分類循環開始
}

print <<<EOT
 -->
	<tr class="tr1">
		<td class="td2"><input name="new_category_title" type="text" value="" class="input input_wa" /></td>
	</tr>
	<tr class="tr1">
		<td class="td2"><span class="btn"><span><button type="submit" onfocus="blur();">提 交</button></span></span></td>
	</tr>
</table>
</div>
</form>
<script type="text/javascript">
	function isDel(url) {
		if (confirm('是否確認刪除？')) {
			window.location.href=url;
		}
	}
</script>
<!--
EOT;
?>
-->