<!--
<?php
print<<<EOT
-->
<div class="MainContainers">
  <div class="Header"><span class="tag">添加分类</span><span class="more">&gt;&gt;</span></div>
  <div class="Conter">
  <table class="ListTable">
    <tr> 
      <td class='Left'>  
        <form action="index.php?lfj=$lfj&action=addsort" method=POST> 
          <span class=bold>添加新分类-</span>&nbsp;名称 
          <input type=text name="name" size=10>
          <input type=submit value="提 交" name="submit"> 
        </form>
      </td>
      </tr>
  </table>
  </div>
</div>

 
<form name="formlist" method="post" action="index.php?lfj=$lfj&action=sortorder">
<div class="MainContainers">
  <div class="Header"><span class="tag">编辑分类</span><span class="more">&gt;&gt;</span></div>
  <div class="Conter">
        <ul class='notes'>
          <li>注意:<font color="#FF0000">分类排序的规则是,数值大的排在前面,只能是同一级的进行排序</font> </li>
        </ul>  
        <table class='ListTable' id='list_sort'>
          <tr> 
            <th width="4%">FID</th>
            <th  width="50%"><span class=bold>分类</span>名称</th>
            <th width="6%">排序</th>
            <th width="6%">设置</th>
            <th width="6%">内容</th>
            <th width="6%">删除</th>
          </tr>
          <!--
EOT;
foreach($listdb AS $key=>$rs){
print <<<EOT
-->
          <tr class="trA" onmouseover="this.className='trB'" onmouseout="this.className='trA'"> 
            <td ><b><font color="#FF0000">$rs[fid]</font></b></td>
            <td class='Left'> 
              <input type="checkbox" name="fiddb[{$rs[fid]}]" value="$rs[name]" style="border:0px;">
              【{$rs[name]}】<span class='sort_span'></span></td>
            <td > 
              <input type='text' name='order[{$rs[fid]}]' value='$rs[list]' size='5'>
            </td>
            <td ><a href='?lfj=$lfj&job=editsort&fid=$rs[fid]' title='点击修改' class='edit'></a></td>
            <td ><a href='index.php?lfj=jfadmin&job=listjf&fid=$rs[fid]'><img alt='' src='../member/images/art_icon.gif' border=0></a></td>
            <td ><a href="?lfj=$lfj&action=delsort&fid=$rs[fid]" onclick="return confirm('你确实要删除吗?不可恢复');" title='点击删除' class='del'></a></td>
          </tr>
          <!--
EOT;
}print <<<EOT
-->
        </table>
        <div class='submits'>
          <input type="button" onclick="CheckAll('all')" name="Submit2" value="全选" />
          <input type="button" onClick='CheckAll()' name="Submit2" value="反选" /> 
          <input type="submit" name="Submit2" value="修改栏目排序" onclick="postlist('list')">
          <SCRIPT LANGUAGE="JavaScript">
<!--
function postlist(t){
	if(t=='list'){
		document.formlist.action="index.php?lfj=$lfj&action=sortorder";
	}else{
		document.formlist.action="index.php?lfj=$lfj&job=batch_edit";
	}
	document.formlist.submit();
}
function CheckAll(va){
	form=document.formlist
	for (var i=0;i<form.elements.length;i++){
		var e = form.elements[i];
		if(va=='all'){
			e.checked = true;
		}else{
			e.checked == true ? e.checked = false : e.checked = true;
		}
	}
}
//-->
</SCRIPT>
          <script language="JavaScript" src="images/sort.js"></script>
          <script language="JavaScript">
<!--
load_sort_td($webdb[article_show_step]);
//-->
</script>
        </div>
    </div>
  </div>
</form>
<!--
EOT;
?>
-->
