<?php (!defined('IN_ADMIN') || !defined('IN_MUDDER')) && exit('Access Denied'); ?>
<div id="body">
<form method="post" action="admincp.php?action=<?=$action?>&file=<?=$file?>&op=<?=$op?>&">
    <div class="space">
        <div class="subtitle"><?=$subtitle?></div>
        <table class="maintable" border="0" cellspacing="0" cellpadding="0">
            <tr class="altbg1">
                <td width="10%">删?</td>
                <td width="20%">模板名称</td>
                <td width="30%">所在目录</td>
                <td width="30%">版权信息</td>
                <!--<td width="10%">编辑</td>-->
            </tr>
            <? if($templates) { foreach($templates as $template) { ?>
            <tr>
                <td><input type="checkbox" <?if($template['bind']){?>disabled<?}else{?>name="templateids[]" value="<?=$template['templateid']?>"<?}?> /></td>
                <td><input type="text" name="templates[<?=$template['templateid']?>][name]" value="<?=$template['name']?>" class="txtbox3" /></td>
                <td><input type="text" name="templates[<?=$template['templateid']?>][directory]" value="<?=$template['directory']?>" class="txtbox2" /></td>
                <td><?=$template['copyright']?></td>
                <!--<td><a href="#">编辑</a></td>-->
            </tr>
            <?}}?>
            <tr class="altbg1">
                <td>增加:</td>
                <td><input type="text" name="newtemplate[name]" class="txtbox3" /></td>
                <td><input type="text" name="newtemplate[directory]" class="txtbox2" /></td>
                <td colspan="2"><input type="text" name="newtemplate[copyright]" class="txtbox2" /></td>
            </tr>
            <tr class="altbg1">
                <td colspan="5">
                    <input type="button" name="select" value="全选" class="btn2" onclick="checkbox_checked('templateids[]');" />
                </td>
            </tr>
        </table>
        <br /><center><input type="submit" name="templatesubmit" value=" 提交 " class="btn" /></center>
    </div>
</form>
</div>