<!--{template 'head'}-->
<script type="text/javascript">
var action = '{$action}'; 
function doCheck(){
	if(document.myform.channelname.value == ""){
		alert("请输入频道名称");
		return false;
	}
	if(document.myform.channelid.value == ""){
		alert("请输入频道ID");
		return false;
	}
	var type = 0;
	if(action == 'add'){
		if($('cattype').checked == true){
			type = 1;
		}
	}else{
		type = $('cattype').value;
	}

	if( type==1){	
		if(document.myform.channeldir.value==""){
			alert("请输入频道目录");
			return false;
		}
		if(document.myform.channeltitle.value==""){
			alert("请输入频道的属性");
			return false;
		}
		if(document.myform.channelitem.value==""){
			alert("请输入属性的单位");
			return false;
		}
	}else{
		if(document.myform.url.value==""){
			alert("请输入链接地址");
			return false;
		}
	}
	$('for-submit').disabled = true;
	return true;
}
function changeChannelMod(type){
	if(type == 1){
		$('url').style.display = 'none';
	}else{
		$('url').style.display = '';
	}
	for(var i=1;i<4;i++){
		$('TabTitle'+i).style.display = type ? "" : 'none';
	}
}
</script>
<script type="text/javascript">
setSubject("系统设置");
</script>
<table width='100%' border='0' align='center' cellpadding='2' cellspacing='1' class='tableborder'>
	<tr>
		<td class="tablerow">
			管理选项：
			<a href='system.php?sys=channel&action=modify'><!--{if $action=='modify'}--><font color=red>频道管理首页</font><!--{else}-->频道管理首页<!--{/if}--></a>
			&nbsp;|&nbsp;<a href='system.php?sys=channel&action=add'><!--{if $action=='add'}--><font color=red>添加新频道</font><!--{else}-->添加新频道<!--{/if}--></a>
			&nbsp;|&nbsp;<a href='system.php?sys=channel&action=info'>刷新频道信息</a>
		</td>
	</tr>
</table>

<!--{if $action=='modify'}-->
<form method="post" action="system.php?sys=channel&action=updateorder">
	<table width='100%' border='0' align='center' cellpadding='0' cellspacing='0' class='tableborder' id="mytable">
		<tr height='22'>
			<th width='40' align='center'>ID</th>
			<th width='50' align='center'>排序</th>
			<th width="100" align='center'>频道名称</th>
			<th width='54' align='center'>打开方式</th>
			<th width='60' align='center'>频道类型</th>
			<th align='center'>频道目录/链接地址</th>
			<th width='64' align='center'>项目名称</th>
			<th width='64' align='center'>功能模型</th>
			<th width='64' align='center'>频道状态</th>
			<th width='100' align='center'>操作</th>
		</tr>
		<!--{loop $channels $channel}-->
		<tr class="item">
			<td align='center'>{$channel[channelid]}</td>
			<td align='center'><input type=text class="f-text" size=4 value={$channel[displayorder]} name=displayorder[{$channel[channelid]}]></td>
			<td align='center'><a href=<!--{if $channel[link]}-->'{$channel[url]}' target=_blank<!--{else}-->'system.php?sys=acategory&channelid={$channel[channelid]}&action=modify'<!--{/if}-->>{$channel[channelname]}</a></td>
			<td align='center'><!--{if $channel[target]=='_self'}-->原窗口<!--{else}-->新窗口<!--{/if}--></td>
			<td align='center'><!--{if $channel[link]}-->外部频道<!--{else}--><font color=blue>内部频道</font><!--{/if}--></td>
			<!--{if $channel[link]}-->
			<td colspan=3 style="padding-left:5px;"><font color=red>{$channel[url]}</font></td>
			<!--{else}-->
			<td style="padding-left:5px;">目录：{$channel[channeldir]}</td>
			<td align='center'>{$channel[channeltitle]}</td>
			<td align='center'>{$_MODULE[$channel[channelselect]][name]}</td>
			<!--{/if}-->
			<td align='center'><!--{if $channel[show]}-->正常<!--{else}--><font color=green>禁用</font><!--{/if}--></td>
			<td align='center'><a href='system.php?sys=channel&action=edit&channelid={$channel[channelid]}'>修改</a>&nbsp;<!--{if $channel[show]}--><a href='system.php?sys=channel&action=disable&channelid={$channel[channelid]}&show=0' onclick="return makeSure()">禁用</a><!--{else}--><a href='system.php?sys=channel&action=disable&channelid={$channel[channelid]}&show=1' onclick="return makeSure()">启用</a><!--{/if}-->&nbsp;<!--{if !$channel[system]}--><a href='system.php?sys=channel&action=del&channelid={$channel[channelid]}' onclick="return makeSure()">删除</a><!--{/if}--></td>
		</tr>
		<!--{/loop}-->
		<tr>
			<td colspan=10 align="center" id="submitrow" class="tablerowl"><input type="submit" class="f-button" value="   保存   " /></td>
		</tr>
	</table>
</form>
<!--{/if}-->

<!--{if $action=='add'}-->
	<table cellpadding="1" cellspacing="1" class='tableborder'>
	<tr>
		<td colspan=2>
				<table width='100%'  border='0' align='center' cellpadding='0' cellspacing='0'  class="tableborder">
					<tr align='center'>
						<td id='TabTitle0' class='title6' onclick='ShowTabs(0)' height=24>基本选项</td>
						<td id='TabTitle1' class='title5' onclick='ShowTabs(1)'>高级选项</td>
						<td id='TabTitle2' class='title5' onclick='ShowTabs(2)'>文件上传</td>
						<td id='TabTitle3' class='title5' onclick='ShowTabs(3)'>图片设置</td>
						<td>&nbsp;</td>
					</tr>
				</table>
			</td>
		</tr>
	</table>
<form name="myform" method="post" action="system.php?sys=channel&action=add" onsubmit="return doCheck();">
	<input type="hidden" name="insert" value="1">
	<table cellpadding="2" cellspacing="1" cellpadding='1' cellspacing='1' class='tableborder border'>
			<tbody id='Tabs0' style='display:'>
				<tr>
					<td width="20%" class="tablerowl"><font color=red>功能类型</font></td>
					<td width="80%" class="tablerow">
						<select name="channelselect">
							<!--{loop $_MODULE $list}-->
								<!--{if $list[is_morechannel] == 1}-->
								<option value="{$list[id]}">{$list[name]}</option>
								<!--{/if}-->
							<!--{/loop}-->
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>频道名称</font></td>
					<td class="tablerow"><input type="text" name="channelname" size="35" class="f-text"></td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>频道  &nbsp;ID</font></td>
					<td class="tablerow"><input type="text" name="channelid" size="15" value="" class="f-text"> <font color=blue>数字，不能与现有的频道ID相同</font></td>
				</tr>
				<tr>
					<td class="tablerowl" ><font color=red>频道目录</font></td>
					<td class="tablerow"><input name='channeldir' id='channeldir' type='text' size='15' maxlength='20' class="f-text"> <font color=blue>只能是英文，不能带空格或“\”、“/”等符号</font></td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>频道属性</font></td>
					<td class="tablerow"><input type="text" class="f-text" name="channeltitle" size="20"> <font color=blue>比如网络学院的的属性为文章</font></td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>属性单位</font></td>
					<td class="tablerow"><input type="text" class="f-text" name="channelitem" size="20"> <font color=blue>比如文章的单位为篇</font></td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>打开方式</font></td>
					<td class="tablerow">
						<select name="target">
							<option value="_blank">新窗口</option>
							<option value="_self">原窗口</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>是否开放</font></td>
					<td class="tablerow">
						<div class="modify-cate">
							<input name='show' type='radio' value='1' checked id="show_1"><label for="show_1">是</label>
							<input type='radio' name='show' value='0' id="show_0"><label for="show_0">否</label> 
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">关闭频道首页</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input name='close_index' type='radio' value='1' id="close_index_1"><label for="close_index_1">是</label> 
							<input name='close_index' type='radio' value='0' checked id="close_index_0"><label for="close_index_0">否</label>
						</div>
					</td>
				</tr>	
				<tr>
					<td class="tablerowl">频道首页静态</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input name='is_html' type='radio' value='1' checked id="is_html_1"><label for="is_html_1">是</label>
							<input type='radio' name='is_html' value='0' id="is_html_0"><label for="is_html_0">否</label> 
						</div>
					</td>
				</tr>				
				<tr>
					<td class="tablerowl">频道类型</td>
					<td class="tablerow" height="29">
						<div class="modify-cate">
							<input name='cattype' type='radio' value='1' id='cattype' checked onclick="changeChannelMod(1);" /><label for="cattype">内部频道</label>
							<input name='cattype' type='radio' value='0' id='cattype_0' onclick="changeChannelMod(0);"><label for="cattype_0">外部链接</label> 
							<input name='url' type='text' id='url' size='40' maxlength='200' class="f-text" style="display:none;" >
						</div>
					</td>
				</tr>

				<tr>
					<td class="tablerowl">显示顺序</td>
					<td class="tablerow"><input type="text" name="displayorder" size="35" value="1000" class="f-text"></td>
				</tr>
			</tbody>
			<tbody id='Tabs1' style='display:none'>
				<tr>
					<td width="20%" class="tablerowl">频道简介</td>
					<td width="80%" class="tablerow"><textarea rows="6" cols="36" name="description"></textarea></td>
				</tr>
				<tr>
					<td  class="tablerowl">绑定域名</td>
					<td  class="tablerow"><input type=text class="f-text" name='domain' value='' size="40" /> <font color="blue">必须以http开始的绝对路径 如http://article.qmecms.com</font></td>
				</tr>
				<tr>
					<td class="tablerowl">默认风格</td>
					<td class="tablerow">
						<select size="1" name="skin">
							<!--{loop $templatefiles $templatefile}-->
							<option <!--{if $templatefile=='default'}-->selected<!--{/if}--> value="{$templatefile}">{$templatefile}</option>
							<!--{/loop}-->
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">频道首页模板</td>
					<td class="tablerow">
						<input type=text size=40 class="f-text"  name='index_template' id="index_template" value=""> <input class="f-button" type="button" value="选择模版" onclick="SelectBrowse('{W_P}admin/images/browse.html?type=read&channelid=-1&callback=getDir','index_template',550,360);"/>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">生成HTML文件</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="text" class="f-text" name="html_type" size="10" value=".html"> 选择
							<select name="ext" onchange="javascript:myform.html_type.value=myform.ext.value">
								<option value='.htm' >.htm</option>
								<option value='.html' >.html</option>
								<option value='.shtm' >.shtm</option>
								<option value='.shtml' selected>.shtml</option>
								<option value='.php' >.php</option>
							</select>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">HTML存放方式</td>
					<td class="tablerow">
						<select name="html_date_path">
							<option value='1' >频道目录/html/年/</option>
							<option value='2'>频道目录/html/年月/</option>
							<option value='3'>频道目录/html/年/月/</option>
							<option value='4'>频道目录/html/年/月/日/</option>
							<option value='5'>频道目录/栏目目录/年/</option>
							<option value='6'>频道目录/栏目目录/年月/</option>
							<option value='7' selected>频道目录/栏目目录/年/月/</option>
							<option value='8'>频道目录/栏目目录/年/月/日/</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">HTML文件前缀</td>
					<td class="tablerow">
						<input type="text" class="f-text" name="html_pre" size="10" value="qmecms_">
						<font color=blue>* 格式如：“article_12345.html”中的article_</font>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">自动生成HTML</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input name='is_auto' type='radio' value='1' id="is_auto_1" checked /><label for="is_auto_1">是</label>
							<input type='radio' name='is_auto' value='0' id="is_auto_0" /><label for="is_auto_0">否</label> <font color=blue>如果频道更新频繁,建议关闭</font>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">显示表单选项</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="hidden" name="show_special" value="1" />
							<input type="checkbox" name="show_money" value="1" checked id="show_money" /><label for="show_money">收费选项</label>
							<input type="checkbox" name="show_related" value="1" id="show_related" /><label for="show_related">相关内容</label>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">开启评论审核</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="radio" name="coment_pass" value="0" id="coment_pass_0" checked><label for="coment_pass_0">打开</label>
							<input type="radio" name="coment_pass" value="1" id="coment_pass_1" ><label for="coment_pass_1">关闭</label>
						</div>
					</td>
				</tr>
			</tbody>
			<tbody id='Tabs2' style='display:none'>
				<tr>
					<td class="tablerowl">允许上传</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="radio" name="allow_upload" value="1" id="allow_upload_1" checked><label for="allow_upload_1">是</label>
							<input type="radio" name="allow_upload" value="0" id="allow_upload_0"><label for="allow_upload_0">否</label>
						</div>
					</td>
				</tr>
				<tr>
					<td width="20%"  class="tablerowl">存放方式</td>
					<td width="80%"  class="tablerow">
						<select name="upload_date_path">
							<option value='1'>年/</option>
							<option value='2'>年月/</option>
							<option value='3'>年月日/</option>
							<option value='4'>年/月/</option>
							<option value='5' selected>年/月/日/</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">文件大小</td>
					<td class="tablerow">
						<input type="text"  class="f-text" name="upload_size" size="10" value="500"> <b>KB</b>
						<font color=blue>当前服务器支持最大上传文件 {$systemMaxUpload}KB</font>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">文件类型</td>
					<td class="tablerow"><input type="text"  class="f-text" name="upload_type" size="60" value="rar|zip|exe|gif|jpg|bmp|png|swf"> <font color=blue>多种文件类型之间用“|”分隔</font></td>
				</tr>
			</tbody>
			<tbody id='Tabs3' style='display:none'>
				<tr>
					<td width="20%"  class="tablerowl">图片缩放宽度</td>
					<td width="80%"  class="tablerow"><input type="text"  class="f-text" name="pic_width" size="10" value="120"></td>
				</tr>
				<tr>
					<td class="tablerowl">图片缩放高度</td>
					<td class="tablerow"><input type="text"  class="f-text" name="pic_height" size="10" value="160"></td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">图片缩放是否裁图</div></td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="radio"  name="pic_cut" value='0' id="pic_cut_0" /><label for="pic_cut_0">不截图 </label>
							<input type="radio"  name="pic_cut" value='1' id="pic_cut_1" checked /><label for="pic_cut_1">截图</label> <font color='blue'></font>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">是否添加水印</div></td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="radio"  name="water" value='0' id="water_0" checked  /><label for="water_0">不添加 </label>
							<input type="radio"  name="water" value='1' id="water_1"  /><label for="water_1">文字水印</label>
							<input type="radio"  name="water" value='2' id="water_2"  /><label for="water_2">图片水印</label> 
						</div>
						<p><font color="blue" style="margin-top:5px">图片水印，只有当图片的宽和高都大于300px时，才有效</font></p>
						<p><font color="blue" style="margin-top:5px">文字水印，只有填写下面的文字才有效</font></p>
						<!--{if !function_exists("imagettftext")}--><p><font color="red" style="margin-top:5px">您的服务器不支持GD FreeType，不能使用文字水印</font></p><!--{/if}-->
						<!--{if !is_file(R_P . '/include/table/simsun.ttc')}--><p><font color="red" style="margin-top:5px">字体文件（include/table/simsun.ttc）不存在，不能使用文字水印</font></p><!--{/if}-->
					</td>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">文字水印</div></td>
					<td class="tablerow">
						<div class="modify-cate">
						<input type="text" value="" name="water_word" class="f-text" size="24" />
							<select name="water_size" >
								<option value="12">12px</option>
								<option value="14">14px</option>
								<option value="16" selected>16px</option>
								<option value="18">18px</option>
								<option value="20">20px</option>
								<option value="22">22px</option>
								<option value="24">24px</option>
								<option value="26">26px</option>
								<option value="28">28px</option>
								<option value="30">30px</option>
							</select>
							<input name="water_color" id="water_color" type="text" size="6" class="f-text" value="#000000"  onchange="this.style.backgroundColor=this.value" /><input type="button" onclick="return getColor(this, 'water_color');" value="选择颜色" class="f-button" />
							<font color="blue" style="margin-left:30px">长度最多20个字节</font>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">水印位置</div></td>
					<td class="tablerow">
						<table border="1" cellspacing="1" cellpadding='1' width="150" height="90">
							<tr>
								<td width="75" align="center">
									<div class="modify-cate"><input type="radio" name="water_position" value="1" id="water_position_1" /> <label for="water_position_1">左上</label></div>
								</td>
								<td width="75" align="center">
									<div class="modify-cate"><input type="radio" name="water_position" value="3" id="water_position_3" /> <label for="water_position_3">右上</label></div>
								</td>
							</tr>
							<tr>
								<td align="center">
									<div class="modify-cate"><input type="radio" name="water_position" value="2" id="water_position_2" /> <label for="water_position_2">左下</label></div>
								</td>
								<td align="center">
									<div class="modify-cate"><input checked type="radio" name="water_position" value="4" id="water_position_4" /> <label for="water_position_4">右下</label></div>
								</td>
							</tr>
						</table>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">水印图片</div></td>
					<td class="tablerow" style="height:34px;font-size:14px;">
						<font color="blue">图片位于：images/water.png</font>
					</td>
				</tr>
			</tbody>
			<tbody>
				<tr>
					<td class="tablerowl" colspan=2 height=35>
						<input name='is_html' type='hidden' value='1' />
						<input name='is_html_content' type='hidden' value='1' />
						<input name="submit" id="for-submit" class="f-button" type=submit value="确定">
					</td>
				</tr>
			</tbody>
		</table>
	</form>
<!--{/if}-->


<!--{if $action=='edit'}-->
	<table cellpadding="2" cellspacing="1" cellpadding='1' cellspacing='1' class='tableborder'>
		<tr>
		<td colspan=2>
				<table width='100%'  border='0' align='center' cellpadding='0' cellspacing='0'  class="tableborder">
					<tr align='center'>
						<td id='TabTitle0' class='title6' onclick='ShowTabs(0)' height=24>基本选项</td>
						<!--{if $channel['link'] == 0}-->
							<td id='TabTitle1' class='title5' onclick='ShowTabs(1)'>高级选项</td>
							<td id='TabTitle2' class='title5' onclick='ShowTabs(2)'>文件上传</td>
							<td id='TabTitle3' class='title5' onclick='ShowTabs(3)'>图片设置</td>
						<!--{/if}-->
						<td>&nbsp;</td>
					</tr>
				</table>
			</td>
		</tr>
	</table>
	<form name="myform" method="post" action="system.php?sys=channel&action=edit&channelid={$channelid}"  onsubmit='return doCheck();'>
		<input type="hidden" name="update" value="1">
		<input type="hidden" name="id" value="{$channel[id]}">
		<table cellpadding="2" cellspacing="1" cellpadding='1' cellspacing='1' class='tableborder border'>
			<tbody id='Tabs0' style='display:'>
				<tr>
					<td width="20%" class="tablerowl"><font color=red>功能类型</font></td>
					<td width="80%" class="tablerow">
						<select name="channelselect" disabled>
							<!--{loop $_MODULE $list}-->
							<option <!--{if $channel[channelselect]==$list[id]}--> selected<!--{/if}--> value="{$list[id]}">{$list[name]}</option>
							<!--{/loop}-->
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>频道名称</font></td>
					<td class="tablerow"><input type="text" name="channelname" value="{$channel[channelname]}" size="35" class="f-text"></td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>频道  &nbsp;ID</font></td>
					<td class="tablerow"><input type="text" name="channelid" size="15" value="{$channel[channelid]}" disabled class="f-text"> <font color=blue>不能与现有的频道ID相同</font></td>
				</tr>
				<tr>
					<td class="tablerowl" ><font color=red>频道目录</font></td>
					<td class="tablerow"><input name='channeldir' id='channeldir' value="{$channel[channeldir]}" type='text' size='15' maxlength='20' class="f-text"> <font color=blue>只能是英文，不能带空格或“\”、“/”等符号</font></td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>频道属性</font></td>
					<td class="tablerow"><input type="text" class="f-text" name="channeltitle"  value="{$channel[channeltitle]}" size="20"> <font color=blue>比如网络学院的的属性为文章</font></td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>属性单位</font></td>
					<td class="tablerow"><input type="text" class="f-text" name="channelitem"  value="{$channel[channelitem]}"  size="20"> <font color=blue>比如文章的单位为篇</font></td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>打开方式</font></td>
					<td class="tablerow">
						<select name="target">
							<option value="_self"<!--{if $channel[target]=='_self'}--> selected<!--{/if}-->>原窗口</option>
							<option value="_blank"<!--{if $channel[target]=='_blank'}--> selected<!--{/if}-->>新窗口</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><font color=red>是否开放</font></td>
					<td class="tablerow">
						<div class="modify-cate">
							<input name='show' type='radio' value='1' <!--{if $channel[show]}--> checked<!--{/if}--> id="show_1"><label for="show_1">是</label>
							<input type='radio' name='show' value='0' <!--{if $channel[show] == 0}--> checked<!--{/if}--> id="show_0"><label for="show_0">否</label> 
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">关闭频道首页</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input name='close_index' type='radio' value='1' id="close_index_1"<!--{if $channel[close_index] == 1}--> checked<!--{/if}-->><label for="close_index_1">是</label> 
							<input name='close_index' type='radio' value='0' id="close_index_0"<!--{if $channel[close_index] == 0}--> checked<!--{/if}-->><label for="close_index_0">否</label>
						</div>
					</td>
				</tr>	
				<tr>
					<td class="tablerowl">频道首页静态</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input name='is_html' type='radio' value='1' <!--{if $channel[is_html]}--> checked<!--{/if}--> checked id="is_html_1"><label for="is_html_1">是</label>
							<input type='radio' name='is_html' value='0' <!--{if $channel[is_html] == 0}--> checked<!--{/if}--> id="is_html_0"><label for="is_html_0">否</label> 
						</div>
					</td>
				</tr>					
				<tr>
					<td class="tablerowl">频道类型</td>
					<td class="tablerow" height="29">
						<div class="modify-cate">
						<!--{if $channel[link] == 0}-->
							<input name='cattype' id="cattype" type='hidden' value='1' /><font color="blue">内部频道</font>
						<!--{else}-->
							<input name='cattype' id="cattype"  type='hidden' value='0' /><font color="blue">外部链接</font> 
							<input name='url' type='text' id='url' size='40' maxlength='200' class="f-text" value="{$channel[url]}" >
						<!--{/if}-->
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">显示顺序</td>
					<td class="tablerow"><input type="text" name="displayorder" value="{$channel[displayorder]}"  size="35" value="1000" class="f-text"></td>
				</tr>
			</tbody>
			<tbody id='Tabs1' style='display:none'>
				<tr>
					<td width="20%" class="tablerowl">频道简介</td>
					<td width="80%" class="tablerow"><textarea rows="6" cols="36" name="description">{$channel[description]}</textarea></td>
				</tr>
				<tr>
					<td  class="tablerowl">绑定域名</td>
					<td  class="tablerow"><input type=text class="f-text" name='domain' value="{$channel[domain]}" size="40" /> <font color="blue">必须以http开始的绝对路径 如http://article.qmecms.com</font></td>
				</tr>
				<tr>
					<td class="tablerowl">默认风格</td>
					<td class="tablerow">
						<select size="1" name="skin">
							<!--{loop $templatefiles $templatefile}-->
							<option <!--{if $channel[skin]==$templatefile}-->selected<!--{/if}--> value="{$templatefile}">{$templatefile}</option>
							<!--{/loop}-->
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">频道首页模板</td>
					<td class="tablerow">
						<input type=text size=40 class="f-text"  name='index_template' id="index_template"  value="{$channel[index_template]}"> <input class="f-button" type="button" value="选择模版" onclick="SelectBrowse('{W_P}admin/images/browse.html?type=read&channelid=-1&callback=getDir','index_template',550,360);"/>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">生成HTML文件</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="text" class="f-text" name="html_type" size="10"  value="{$channel[html_type]}"> 选择
							<select name="ext" onchange="javascript:myform.html_type.value=myform.ext.value">
								<option value='.htm' >.htm</option>
								<option value='.html' >.html</option>
								<option value='.shtm' >.shtm</option>
								<option value='.shtml'>.shtml</option>
								<option value='.php' >.php</option>
							</select>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">HTML存放方式</td>
					<td class="tablerow">
						<select name="html_date_path">
							<option<!--{if $channel[html_date_path]==1}--> selected<!--{/if}--> value='1'>频道目录/html/年/</option>
							<option<!--{if $channel[html_date_path]==2}--> selected<!--{/if}--> value='2'>频道目录/html/年月/</option>
							<option<!--{if $channel[html_date_path]==3}--> selected<!--{/if}--> value='3'>频道目录/html/年/月/</option>
							<option<!--{if $channel[html_date_path]==4}--> selected<!--{/if}--> value='4'>频道目录/html/年/月/日/</option>
							<option<!--{if $channel[html_date_path]==5}--> selected<!--{/if}--> value='5'>频道目录/栏目目录/年/</option>
							<option<!--{if $channel[html_date_path]==6}--> selected<!--{/if}--> value='6'>频道目录/栏目目录/年月/</option>
							<option<!--{if $channel[html_date_path]==7}--> selected<!--{/if}--> value='7'>频道目录/栏目目录/年/月/</option>
							<option<!--{if $channel[html_date_path]==8}--> selected<!--{/if}--> value='8'>频道目录/栏目目录/年/月/日/</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">HTML文件前缀</td>
					<td class="tablerow">
						<input type="text" class="f-text" name="html_pre" size="10"  value="{$channel[html_pre]}">
						<font color=blue>* 格式如：“article_12345.html”中的article_</font>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">自动生成HTML</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input name='is_auto' type='radio' value='1' id="is_auto_1" <!--{if $channel[is_auto]==1}--> checked<!--{/if}--> /><label for="is_auto_1">是</label>
							<input type='radio' name='is_auto' value='0' id="is_auto_0" <!--{if $channel[is_auto]==0}--> checked<!--{/if}--> /><label for="is_auto_0">否</label> <font color=blue>如果频道更新频繁,建议关闭</font>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">显示表单选项</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="hidden" name="show_special" value="1" />
							<input type="checkbox" name="show_money" value="1" id="show_money"  <!--{if $channel[show_money]==1}--> checked<!--{/if}-->/><label for="show_money">收费选项</label>
							<input type="checkbox" name="show_related" value="1" id="show_related" <!--{if $channel[show_related]==1}--> checked<!--{/if}--> /><label for="show_related">相关内容</label>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">开启评论审核</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="radio" name="coment_pass" value="0" id="coment_pass_0" <!--{if $channel[coment_pass]==0}--> checked<!--{/if}-->><label for="coment_pass_0">打开</label>
							<input type="radio" name="coment_pass" value="1" id="coment_pass_1" <!--{if $channel[coment_pass]==1}--> checked<!--{/if}-->><label for="coment_pass_1">关闭</label>
						</div>
					</td>
				</tr>
			</tbody>
			<tbody id='Tabs2' style='display:none'>
				<tr>
					<td class="tablerowl">允许上传</td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="radio" name="allow_upload" value="1" id="allow_upload_1" <!--{if $channel[allow_upload]==1}--> checked<!--{/if}-->><label for="allow_upload_1">是</label>
							<input type="radio" name="allow_upload" value="0" id="allow_upload_0" <!--{if $channel[allow_upload]==0}--> checked<!--{/if}-->><label for="allow_upload_0">否</label>
						</div>
					</td>
				</tr>
				<tr>
					<td width="20%"  class="tablerowl">存放方式</td>
					<td width="80%"  class="tablerow">
						<select name="upload_date_path">
							<option<!--{if $channel[upload_date_path]==1}--> selected<!--{/if}--> value='1'>年/</option>
							<option<!--{if $channel[upload_date_path]==2}--> selected<!--{/if}--> value='2'>年月/</option>
							<option<!--{if $channel[upload_date_path]==3}--> selected<!--{/if}--> value='3'>年月日/</option>
							<option<!--{if $channel[upload_date_path]==4}--> selected<!--{/if}--> value='4'>年/月/</option>
							<option<!--{if $channel[upload_date_path]==5}--> selected<!--{/if}--> value='5'>年/月/日/</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">文件大小</td>
					<td class="tablerow">
						<input type="text"  class="f-text" name="upload_size" size="10" value="{$channel[upload_size]}"> <b>KB</b>
						<font color=blue>当前服务器支持最大上传文件 {$systemMaxUpload}KB</font>
					</td>
				</tr>
				<tr>
					<td class="tablerowl">文件类型</td>
					<td class="tablerow"><input type="text"  class="f-text" name="upload_type" size="60"  value="{$channel[upload_type]}"> <font color=blue>多种文件类型之间用“|”分隔</font></td>
				</tr>
			</tbody>
			<tbody id='Tabs3' style='display:none'>
				<tr>
					<td width="20%"  class="tablerowl">图片缩放宽度</td>
					<td width="80%"  class="tablerow"><input type="text"  class="f-text" name="pic_width" size="10"  value="{$channel[pic_width]}"></td>
				</tr>
				<tr>
					<td class="tablerowl">图片缩放高度</td>
					<td class="tablerow"><input type="text"  class="f-text" name="pic_height" size="10" value="{$channel[pic_height]}"></td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">图片缩放是否裁图</div></td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="radio"  name="pic_cut" value='0' id="pic_cut_0" <!--{if $channel[pic_cut]==0}--> checked<!--{/if}-->/><label for="pic_cut_0">不截图 </label>
							<input type="radio"  name="pic_cut" value='1' id="pic_cut_1" <!--{if $channel[pic_cut]==1}--> checked<!--{/if}-->/><label for="pic_cut_1">截图</label> <font color='blue'></font>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">是否添加水印</div></td>
					<td class="tablerow">
						<div class="modify-cate">
							<input type="radio"  name="water" value='0' id="water_0" <!--{if $channel[water]==0}--> checked<!--{/if}--> /><label for="water_0">不添加 </label>
							<input type="radio"  name="water" value='1' id="water_1" <!--{if $channel[water]==1}--> checked<!--{/if}--> /><label for="water_1">文字水印</label>
							<input type="radio"  name="water" value='2' id="water_2" <!--{if $channel[water]==2}--> checked<!--{/if}--> /><label for="water_2">图片水印</label> 
						</div>	
						<p><font color="blue" style="margin-top:5px">图片水印，只有当图片的宽和高都大于300px时，才有效</font></p>
						<p><font color="blue" style="margin-top:5px">文字水印，只有填写下面的文字才有效</font></p>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">文字水印</div></td>
					<td class="tablerow">
							<div class="modify-cate">
							<input type="text" value="{$channel[water_word]}" name="water_word" class="f-text" size="24" />
							<select name="water_size" >
								<option value="12"<!--{if $channel[water_size]==12}--> selected<!--{/if}-->>12px</option>
								<option value="14"<!--{if $channel[water_size]==14}--> selected<!--{/if}-->>14px</option>
								<option value="16"<!--{if $channel[water_size]==16}--> selected<!--{/if}-->>16px</option>
								<option value="18"<!--{if $channel[water_size]==18}--> selected<!--{/if}-->>18px</option>
								<option value="20"<!--{if $channel[water_size]==20}--> selected<!--{/if}-->>20px</option>
								<option value="22"<!--{if $channel[water_size]==22}--> selected<!--{/if}-->>22px</option>
								<option value="24"<!--{if $channel[water_size]==24}--> selected<!--{/if}-->>24px</option>
								<option value="26"<!--{if $channel[water_size]==26}--> selected<!--{/if}-->>26px</option>
								<option value="28"<!--{if $channel[water_size]==28}--> selected<!--{/if}-->>28px</option>
								<option value="30"<!--{if $channel[water_size]==30}--> selected<!--{/if}-->>30px</option>
							</select>
							<input name="water_color" id="water_color" type="text" size="6" class="f-text" value="{$channel[water_color]}"  onchange="this.style.backgroundColor=this.value" /><input type="button" onclick="return getColor(this, 'water_color');" value="选择颜色" class="f-button" />
							<font color="blue" style="margin-left:30px">长度最多20个字节</font>
						</div>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">图片水印位置</div></td>
					<td class="tablerow">
						<table border="1" cellspacing="1" cellpadding='1' width="150" height="90">
							<tr>
								<td width="75" align="center"><div class="modify-cate"><input type="radio" name="water_position" value="1" id="water_position_1"<!--{if $channel[water_position]==1}--> checked<!--{/if}--> /> <label for="water_position_1">左上</label></div></td>
								<td width="75" align="center"><div class="modify-cate"><input type="radio" name="water_position" value="3" id="water_position_3"<!--{if $channel[water_position]==3}--> checked<!--{/if}--> /> <label for="water_position_3">右上</label></div></td>
							</tr>
							<tr>
								<td align="center"><div class="modify-cate"><input type="radio" name="water_position" value="2" id="water_position_2"<!--{if $channel[water_position]==2}--> checked<!--{/if}--> /> <label for="water_position_2">左下</label></div></td>
								<td align="center"><div class="modify-cate"><input type="radio" name="water_position" value="4" id="water_position_4"<!--{if $channel[water_position]==4}--> checked<!--{/if}--> /> <label for="water_position_4">右下</label></div></td>
							</tr>
						</table>
					</td>
				</tr>
				<tr>
					<td class="tablerowl"><div class="divbody">水印图片</div></td>
					<td class="tablerow" style="height:34px;font-size:14px;">
						<font color="blue">图片位于：images/water.png</font>
					</td>
				</tr>
			</tbody>
			<tbody>
				<tr>
					<td class="tablerowl" colspan=2>
						<input name='is_html_content' type='hidden' value='1' />
						<input name="submit" type="submit" id='for-submit'  class="f-button"  value="确定">
					</td>
				</tr>
			</tbody>
		</table>
	</form>
<!--{/if}-->


<!--{template 'foot'}-->