?? category_edit.php
字號:
<?php
defined('IN_PHPCMS') or exit('Access Denied');
include admintpl('header');
?>
<script language='JavaScript' type='text/JavaScript'>
function CheckForm(){
if(document.myform.channelname.value==''){
ShowTabs(0);
alert('請輸入欄目名稱!');
document.myform.channelname.focus();
return false;
}
if(document.myform.channeltype[1].checked==true){
if(document.myform.channeldir.value==''){
ShowTabs(0);
alert('請輸入欄目目錄!');
document.myform.channeldir.focus();
return false;
}
}
else{
if(document.myform.linkurl.value==''){
ShowTabs(0);
alert('請輸入欄目的鏈接地址!');
document.myform.linkurl.focus();
return false;
}
}
}
</script>
<body <?php if(!$cattype){ ?>onload="HideTabTitle('none')" <?php } ?>>
<table cellpadding="0" cellspacing="0" border="0" width="100%" height="10">
<tr>
<td></td>
</tr>
</table>
<?=$menu?>
<script language='javascript'>
var tID=0;
function ShowTabs(ID){
if(ID!=tID){
TabTitle[tID].className='title1';
TabTitle[ID].className='title2';
Tabs[tID].style.display='none';
Tabs[ID].style.display='';
tID=ID;
}
}
function HideTabTitle(displayValue,tempType){
for (var i = 1; i < TabTitle.length; i++) {
if(tempType==0&&i==2) {
TabTitle[i].style.display='none';
}
else{
TabTitle[i].style.display=displayValue;
}
}
}
</script>
<form name="myform" method="post" action="?file=category&action=edit&catid=<?=$catid?>&save=1&channelid=<?=$channelid?>&oldparentid=<?=$oldparentid?>" onSubmit='return CheckForm();'>
<table width='100%' border='0' cellpadding='0' cellspacing='0'>
<tr align='center' height='24'>
<td id='TabTitle' class='title2' onclick='ShowTabs(0)'>基本信息</td>
<td id='TabTitle' class='title1' onclick='ShowTabs(1)'>顯示控制</td>
<td id='TabTitle' class='title1' onclick='ShowTabs(2)'>權限設置</td>
<td id='TabTitle' class='title1' onclick='ShowTabs(3)'>收費設置</td>
<td> </td>
</tr>
</table>
<table cellpadding="2" cellspacing="1" class="tableborder">
<tbody id='Tabs' style='display:'>
<th colspan=2>基本信息</th>
<tr>
<td width='30%' class='tablerow'><strong>所屬欄目</strong></td>
<td class='tablerow'>
<?=$parentid?>
<font color="red">*</font>
</td>
</tr>
<tr>
<td class='tablerow'><strong>欄目名稱</strong></td>
<td class='tablerow'><input name='category[catname]' type='text' id='catname' size='40' maxlength='50' value='<?=$catname?>'> <font color="red">*</font></td>
</tr>
<tr>
<td class='tablerow'><strong>欄目圖片</strong></td>
<td class='tablerow'><input name='category[catpic]' type='text' id='catpic' size='40' maxlength='50' value='<?=$catpic?>'> <input type="button" value=" 上傳 " onclick="javascript:openwinx('?mod=phpcms&file=uppic&channelid=<?=$channelid?>&uploadtext=catpic&width=100&height=100','upload','350','200')"></td>
</tr>
<tr>
<td class='tablerow'><strong>欄目說明</strong><br></td>
<td class='tablerow'><input name='category[introduce]' type='text' id='introduce' size='40' maxlength='255' value='<?=$introduce?>'></td>
</tr>
<tr>
<td class='tablerow'><strong>打開方式</strong></td>
<td class='tablerow'>
<input type='radio' name='category[target]' value='_self' <?php if($target=='_self'){ ?> checked <?php } ?>> 在原窗口打開
<input type='radio' name='category[target]' value='_blank' <?php if($target=='_blank'){ ?> checked <?php } ?>> 在新窗口打開
</td>
</tr>
<tr>
<td width='40%' class='tablerow'><strong>Meta Keywords(欄目關鍵詞)</strong><br>針對搜索引擎設置的關鍵詞</td>
<td class='tablerow'><textarea name='category[meta_keywords]' cols='60' rows='2' id='meta_keywords'><?=$meta_keywords?></textarea></td>
</tr>
<tr>
<td width='40%' class='tablerow'><strong>Meta Description(欄目描述)</strong><br>針對搜索引擎設置的網頁描述</td>
<td class='tablerow'><textarea name='category[meta_description]' cols='60' rows='2' id='meta_description'><?=$meta_description?></textarea></td>
</tr>
<tr>
<td class='tablerow'><strong>欄目類型:</strong><br><font color=red>請慎重選擇,欄目一旦添加后就不能再更改欄目類型。</font></td>
<td class='tablerow'>
<input name='category[cattype]' type='radio' value='1' <?php if($cattype){ ?> checked <?php }else{ ?>disabled <?php } ?> onclick="HideTabTitle('',1)">
<font color=blue><b>內部欄目</b></font> 內部欄目具有詳細的參數設置??梢蕴砑幼訖谀亢托畔?。<br>
內部欄目的目錄名:<input name='category[catdir]' type='text' size='20' maxlength='20' value='<?=$catdir?>' disabled> <font color='#FF0000'>注意,目錄名只能是英文</font><br><br>
<input name='category[cattype]' type='radio' value='0' <?php if(!$cattype){ ?> checked <?php }else{ ?>disabled <?php } ?> onclick="HideTabTitle('none')">
<font color=blue><b>外部欄目</b></font> 外部欄目指鏈接到本系統以外的地址中。當此欄目準備鏈接到網站中的其他系統時,請使用這種方式。不能在外部欄目中添加信息,也不能添加子欄目。<br>
外部欄目的鏈接地址:<input name='category[linkurl]' type='text' id='linkurl' value='<?=$linkurl?>' size='40' maxlength='200' <?php if($cattype){ ?>disabled <?php } ?>>
</td>
</tr>
</tbody>
<tbody id='Tabs' style='display:none'>
<th colspan=2>顯示控制</th>
<tr>
<td width='30%' class='tablerow'><strong>欄目風格</strong></td>
<td class='tablerow'>
<?=$skinid?>
</td>
</tr>
<tr>
<td class='tablerow'><strong>欄目首頁模板</strong></td>
<td class='tablerow'>
<?=$templateid?>
</td>
</tr>
<tr>
<td class='tablerow'><strong>欄目信息列表模板</strong></td>
<td class='tablerow'>
<?=$listtemplateid?>
</td>
</tr>
<tr>
<td width='25%' class='tablerow'><strong>欄目下的內容頁默認風格</strong></td>
<td class='tablerow'>
<?=$defaultitemskin?>
</td>
</tr>
<tr>
<td class='tablerow'><strong>欄目下的內容頁默認模板</strong></td>
<td class='tablerow'>
<?=$defaultitemtemplate?>
</td>
</tr>
<tr>
<td class='tablerow'><strong>是否在頂部導航欄顯示</strong></td>
<td class='tablerow'>
<input type='radio' name='category[showonmenu]' value='1' <?php if($showonmenu){ ?> checked <?php } ?>> 是
<input type='radio' name='category[showonmenu]' value='0' <?php if(!$showonmenu){ ?> checked <?php } ?>> 否
</td>
</tr>
<tr>
<td class='tablerow'><strong>是否在父欄目的分類列表處顯示</strong></td>
<td class='tablerow'>
<input type='radio' name='category[islist]' value='1' <?php if($islist){ ?> checked <?php } ?>> 是
<input type='radio' name='category[islist]' value='0' <?php if(!$islist){ ?> checked <?php } ?>> 否
</td>
</tr>
<tr>
<td class='tablerow'><strong>有子欄目時是否可以在此欄目添加信息</strong></td>
<td class='tablerow'>
<input type='radio' name='category[enableadd]' value='1' <?php if($enableadd){ ?> checked <?php } ?>> 是
<input type='radio' name='category[enableadd]' value='0' <?php if(!$enableadd){ ?> checked <?php } ?>> 否
</td>
</tr>
<tr>
<td class='tablerow'><strong>是否啟用此欄目的防止復制、防盜鏈功能</strong></td>
<td class='tablerow'>
<input type='radio' name='category[enableprotect]' value='1' <?php if($enableprotect){ ?> checked <?php } ?>> 是
<input type='radio' name='category[enableprotect]' value='0' <?php if(!$enableprotect){ ?> checked <?php } ?>> 否
</td>
</tr>
<tr>
<td class='tablerow'><strong>子欄目在此欄目頁顯示的信息數</strong></td>
<td class='tablerow'>
<select name='category[showchilditems]' id='showchilditems' style="width:60px">
<?php for($i=1;$i<21;$i++){ ?>
<option value='<?=$i?>' <?php if($i==$showchilditems){ ?>selected <?php } ?>><?=$i?></option>
<?php } ?>
</select>
</td>
</tr>
<tr>
<td class='tablerow'><strong>列表頁每頁顯示的信息數</strong></td>
<td class='tablerow'>
<select name='category[maxperpage]' id='maxperpage' style="width:60px">
<?php for($i=5;$i<101;$i++){ ?>
<option value='<?=$i?>' <?php if($i==$maxperpage){ ?>selected <?php } ?>><?=$i?></option>
<?php } ?>
</select>
</td>
</tr>
<tr>
<td class='tablerow'><strong>此欄目下的信息列表的排序方式</strong></td>
<td class='tablerow'>
<select name='category[itemordertype]' id='itemordertype' style="width:120px">
<option value='1' <?php if($itemordertype==1){ ?>selected <?php } ?>>信息ID(降序)</option>
<option value='2' <?php if($itemordertype==2){ ?>selected <?php } ?>>信息ID(升序)</option>
<option value='3' <?php if($itemordertype==3){ ?>selected <?php } ?>>更新時間(降序)</option>
<option value='4' <?php if($itemordertype==4){ ?>selected <?php } ?>>更新時間(升序)</option>
<option value='5' <?php if($itemordertype==5){ ?>selected <?php } ?>>點擊次數(降序)</option>
<option value='6' <?php if($itemordertype==6){ ?>selected <?php } ?>>點擊次數(升序)</option>
</select>
</td>
</tr>
<tr>
<td class='tablerow'><strong>此欄目下的信息打開方式</strong></td>
<td class='tablerow'>
<input type='radio' name='category[itemtarget]' value='1' <?php if($itemtarget==1){ ?>checked <?php } ?>> 在新窗口打開
<input type='radio' name='category[itemtarget]' value='0' <?php if($itemtarget==0){ ?>checked <?php } ?>> 在原窗口打開
</td>
</tr>
</tbody>
<tbody id='Tabs' style='display:none'>
<th colspan=2>權限設置</th>
<tr>
<td width='30%' class='tablerow'><strong>欄目權限:</strong><br><font color='red'>欄目權限為繼承關系,當欄目設為“認證欄目”時,其下的欄目設為“開放欄目”也無效。相反,如果欄目設為“開放欄目”,其下的欄目可以自由設置權限。</font></td>
<td class='tablerow'>
<table>
<tr><td width='80' valign='top'><input type='radio' name='category[catpurview]' value='0' <?php if(!$catpurview){ ?>checked <?php } ?>>開放欄目</td>
<td>任何人(包括游客)可以瀏覽此欄目下的信息??梢栽跈谀吭O置中再指定具體的權限。</td></tr>
<tr><td width='80' valign='top'><input type='radio' name='category[catpurview]' value='1' <?php if($catpurview){ ?>checked <?php } ?>>認證欄目</td>
<td>游客不能瀏覽,并在下面指定允許瀏覽的會員組。如果欄目設置為認證欄目,則此欄目的“生成HTML”選項只能設為“不生成HTML”。</td></tr>
</table>
</td>
</tr>
<tr>
<td class='tablerow'><strong>允許瀏覽此欄目的用戶組</strong><br>如果欄目權限設置為“認證欄目”,請在此設置允許瀏覽此欄目的會員組</td>
<td class='tablerow'>
<?=$arrgroupid_browse?>
</td>
</tr>
<tr>
<td class='tablerow'><strong>允許查看此欄目信息的用戶組</strong><br>如果欄目權限設置為“認證欄目”,請在此設置允許瀏覽此欄目的會員組</td>
<td class='tablerow'>
<?=$arrgroupid_view?>
</td>
</tr>
<tr>
<td class='tablerow'>
<?=$arrgroupid_add?>
</td>
</tr>
</tbody>
<tbody id='Tabs' style='display:none'>
<th colspan=2>收費設置</th>
<tr>
<td width='300' class='tablerow'><strong>積分獎勵</strong><br>會員在此欄目發表信息時可以得到的積分</td>
<td class='tablerow'>會員在此欄目每發表一條信息,可以得到 <input name='category[creditget]' type='text' value='<?=$creditget?>' size='4' maxlength='4' style='text-align:center'> 分積分</td>
</tr>
<tr>
<td width='300' class='tablerow'><strong>默認收費點數</strong><br>會員在此欄目下添加信息時,該信息默認的收費點券數</td>
<td class='tablerow'><input name='category[defaultpoint]' type='text' value='<?=$defaultpoint?>' size='4' maxlength='4' style='text-align:center'> 點</td>
</tr>
<tr>
<td width='300' class='tablerow'><strong>默認重復收費:</strong><br>會員在此欄目下添加信息時,該信息默認的重復收費方式</td>
<td class='tablerow'>
<input name='category[defaultchargetype]' type='radio' value='0' <?php if(!$defaultchargetype){ ?>checked <?php } ?>>不重復收費<br>
<input name='category[defaultchargetype]' type='radio' value='1' <?php if($defaultchargetype){ ?>checked <?php } ?>>每閱讀一次就重復收費一次(建議不要使用)</td>
</tr>
</tbody>
</table>
<table width="100%" height="25" border="0" cellpadding="0" cellspacing="0">
<tr>
<td align="center"><input type="submit" name="Submit" value="保存設置"></td>
</tr>
</table>
</form>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -