<?php (!defined('IN_ADMIN') || !defined('IN_MUDDER')) && exit('Access Denied'); ?>
<div id="body">
<form method="get" action="admincp.php">
    <input type="hidden" name="action" value="<?=$action?>" />
    <input type="hidden" name="file" value="<?=$file?>" />
    <div class="space">
        <div class="subtitle">搜索TAG标签</div>
        <table class="maintable" border="0" cellspacing="0" cellpadding="0">
            <tr>
                <td width="10%" class="altbg1">TAG标签:</td>
                <td width="25%"><input type="text" name="search_tagname" class="txtbox3" value="<?=$search_tagname?>" /></td>
                <td width="8%" class="altbg1">板块:</td>
                <td width="15%"><select name="search_panelcode">
                    <option value="0" selected="selected">请选择算在板块</option>
                    <?=$_panels_option?>
                </select></td>
                <td width="8%" class="altbg1">状态:</td>
                <td width="10%"><select name="search_closed">
                    <option value="" selected="selected">选择状态</option>
                    <option value="0">正常</option>
                    <option value="1">停用</option>
                </select></td>
                <td width="10%" class="altbg1"><input type="submit" value="搜索" class="btn" /></td>
            </tr>
        </table>
    </div>
</form>
<form method="post" action="admincp.php?action=<?=$action?>&file=<?=$file?>&">
    <div class="space">
        <div class="subtitle">TAG标签管理</div>
        <table class="maintable" border="0" cellspacing="0" cellpadding="0">
            <tr class="altbg1">
                <td width="5%">删?</td>
                <td width="20%">标签名</td>
                <td width="15%">数量</td>
                <td width="20%">状态</td>
                <td width="20%">板块</td>
                <td width="20%">操作</td>
            </tr>
            <? if($tags) { foreach($tags as $tag) { ?>
            <tr>
                <td><input type="checkbox" name="tagnames[]" value="<?=$tag['tagname']?>" /></td>
                <td><a href="<?=$MOD['url']?>tag.php?tagname=<?=rawurlencode($tag['tagname'])?>" target="_blank"><?=$tag['tagname']?></a></td>
                <td><?=$tag['total']?></td>
                <td><?=$tag['closedname']?></td>
                <td><?=$tag['panelname']?></td>
                <td><a href="admincp.php?action=<?=$action?>&file=<?=$file?>&op=changeclosed&tagid=<?=$tag['tagid']?>&closed=0&search_tagname=<?=$search_tagnameenc?>&search_panelcode=<?=$search_panelcode?>&search_closed=<?=$search_closed?>">启用</a>&nbsp;-&nbsp;<a href="admincp.php?action=<?=$action?>&file=<?=$file?>&op=changeclosed&tagid=<?=$tag['tagid']?>&closed=1">停用</a>&nbsp;-&nbsp;<a href="admincp.php?action=<?=$action?>&file=tagedit&tagid=<?=$tag['tagid']?>">编辑</a></a></td>
            </tr>
            <?}}?>
            <tr class="altbg1"><td colspan="6"><input type="button" value="全选" onclick="checkbox_checked('tagnames[]');" class="btn2" /></td></tr>
        </table>
        <?if($multipage){?><div class="multipage"><?=$multipage?></div><?}?>
        <center><input type="submit" name="tagsubmit" value=" 提交 " class="btn" /></center>
    </div>
</form>
</div>