editor_label.asp
来自「个人网站比较简短」· ASP 代码 · 共 1,169 行 · 第 1/5 页
ASP
1,169 行
<!-- #include File="../Start.asp" -->
<%
'**************************************************************
' Software name: PowerEasy SiteWeaver
' Web: http://www.powereasy.net
' Copyright (C) 2005-2008 佛山市动易网络科技有限公司 版权所有
'**************************************************************
'强制浏览器重新访问服务器下载页面,而不是从缓存读取页面
Response.Buffer = True
Response.Expires = -1
Response.ExpiresAbsolute = Now() - 1
Response.Expires = 0
Response.CacheControl = "no-cache"
Dim Title, ModuleType, ChannelShortName, ChannelShowType, imageproperty, rs
Dim editLabel, arrParameter
Dim ClassID, NClassID, IncludeChild, SpecialID, Num, ProductType, IsHot, IsElite, AuthorName, DateNum
Dim OrderType, ShowType, TitleLen, ContentLen, ShowClassName, ShowPropertyType, ShowIncludePic, ShowAuthor
Dim ShowDateType, ShowHits, ShowHotSign, ShowNewSign, ShowTips, ShowCommentLink, UsePage, OpenType, Cols
Dim ImgWidth, ImgHeight, iTimeOut, urltype, CssNameA, CssName1, CssName2, effectID, IntervalLines
'商城
Dim ShowTableTitle, TableTitleStr, ShowProductModel, ShowProductStandard, ShowUnit, ShowStocksType, ShowPriceType
Dim ShowWeight, ShowPrice_Market, ShowPrice_Original, ShowPrice, ShowPrice_Member, ShowDiscount, ShowButtonType, ButtonStyle
Dim CssNameTable, CssNameTitle
'人才招聘
Dim PositionNum, IsUrgent, WorkPlaceNameLen, SubCompanyNameLen, PShowPoints, WShowPoints, SShowPoints, ShowPositionID, ShowPositionName, ShowWorkPlaceName, ShowSubCompanyName, ShowPositionNum, ShowPositionStatus, ShowValidDate, ShowUrgentSign, ShowNum
'是模板还是右键
Dim InsertTemplate
Dim ChannelID, iChannelID, dChannelID
ChannelID = Trim(Request("ChannelID"))
dChannelID = Trim(Request("dChannelID"))
NClassID = False
If dChannelID = "" Then
dChannelID = ChannelID
End If
If ChannelID = "" And iChannelID = "" Then
Response.Write "频道参数丢失!"
Response.End
End If
If ChannelID = "ChannelID" Then
iChannelID = Trim(dChannelID)
Else
ChannelID = PE_CLng(ChannelID)
iChannelID = ChannelID
End If
Dim LabelName
LabelName = Trim(Request("LabelName"))
Title = Trim(Request("Title"))
ModuleType = PE_CLng(Trim(Request("ModuleType")))
ChannelShowType = Trim(Request("ChannelShowType"))
InsertTemplate = PE_CLng(Trim(Request("InsertTemplate")))
If SpecialID = "" Then SpecialID = 0
If Trim(request.querystring("editLabel")) <> "" Then
editLabel = True
End If
Title = Trim(Request("Title"))
If Action = "Modify" Then
Call GetLabelData
If ChannelID = "ChannelID" Then
iChannelID = PE_CLng(Trim(dChannelID))
Else
ChannelID = PE_CLng(ChannelID)
iChannelID = ChannelID
End If
Else
ModuleType = PE_CLng(Trim(Request("ModuleType")))
If Trim(Request("ChannelID")) = "ChannelID" Then
ChannelID = Trim(Request("ChannelID"))
Else
ChannelID = PE_CLng(Trim(Request("ChannelID")))
End If
ChannelShowType = Trim(Request("ChannelShowType"))
InsertTemplate = PE_CLng(Trim(Request("InsertTemplate")))
If Trim(Request("SpecialID")) = "SpecialID" Then
SpecialID = Trim(Request("SpecialID"))
Else
SpecialID = PE_CLng(Trim(Request("SpecialID")))
End If
editLabel = PE_HtmlDecode(Trim(Request.Form("editLabel")))
If ModuleType = 1 Then
ChannelShortName = "文章"
imageproperty = "article"
ElseIf ModuleType = 2 Then
ChannelShortName = "软件"
imageproperty = "Soft"
ElseIf ModuleType = 3 Then
ChannelShortName = "图片"
imageproperty = "Photo"
ElseIf ModuleType = 5 Then
iChannelID = 1000
ChannelShortName = "商品"
imageproperty = "Product"
ElseIf ModuleType = 8 Then
ChannelShortName = "职位"
imageproperty = "Job"
End If
End If
Response.Write "<html><head><title>" & Title & "</title>" & vbCrLf
Response.Write "<meta http-equiv='Content-Type' content='text/html; charset=gb2312'>" & vbCrLf
Response.Write "<link href='../Images/Admin_Style.css' rel='stylesheet' type='text/css'>" & vbCrLf
Response.Write "<base target='_self'>"
Response.Write "</head>" & vbCrLf
Response.Write "<body leftmargin=0 topmargin=0>" & vbCrLf
Response.Write "<form action='editor_label.asp' method='post' name='myform' id='myform'>"
Response.Write " <table width='100%' border='0' align='center' cellpadding='2' cellspacing='1' class='border'>"
Response.Write " <tr class='title'>"
Response.Write " <td height='22' colspan='2' align='center'><strong>" & Title & "</strong></td>"
Response.Write " </tr>"
If ModuleType <> 8 Then
If ModuleType <> 5 Then
Response.Write " <tr class='tdbg'>"
Response.Write " <td height='25' align='right' class='tdbg5'><strong>所属频道:</strong></td>" & vbCrLf
Response.Write " <td height='25'><input type='hidden' name='iChannelID' value='" & ChannelID & "'><select name='ChannelID' onChange='document.myform.submit();'>" & GetChannel_Option(ModuleType, ChannelID) & "</select></td>"
Response.Write " </tr>"
End If
If PE_CLng(iChannelID) > 0 Or ModuleType = 5 Then
Response.Write " <tr class='tdbg'>"
Response.Write " <td height='25' align='right' class='tdbg5'><strong>所属栏目:</strong></td>" & vbCrLf
Response.Write " <td height='25'><select name='ClassID' "
If NClassID = True Then
Response.Write "size='2' multiple style='height:250px;width:400px;'"
Else
Response.Write "size='1'"
End If
Response.Write ">" & GetClass_Channel(iChannelID, Trim(ClassID), NClassID) & "</select>"
Response.Write " <input type='checkbox' name='IncludeChild' value='1' "
If LCase(Trim(IncludeChild)) = "true" Then
Response.Write " checked "
End If
Response.Write " >包含子栏目 <font color='red'><b>注意:</b></font>不能指定为外部栏目 </font>"
Response.Write " <br><input type='checkbox' name='NClassChild' value='1' onClick=""javascript:NClassIDChild()"" "
If NClassID = True Then
Response.Write " checked "
End If
Response.Write " >是否选择多个栏目 <font color='red'><b>注意:</b></font>红色的栏目不能选 </font>"
Response.Write " </td>"
Response.Write " </tr>"
Response.Write " <tr class='tdbg'>"
Response.Write " <td height='25' align='right' class='tdbg5'><strong>所属专题:</strong></td>"
Response.Write " <td height='25' ><select name='SpecialID' id='SpecialID'>" & GetSpecial_Option(iChannelID, SpecialID) & "</select></td>"
Response.Write " </tr>"
Else
Response.Write "<INPUT TYPE='hidden' name='ClassID' value='0' >"
Response.Write "<INPUT TYPE='hidden' name='NClassChild' value='0' >"
Response.Write "<INPUT TYPE='hidden' name='IncludeChild' value='true' >"
Response.Write "<INPUT TYPE='hidden' name='SpecialID' value='0' >"
End If
Response.Write " <tr class='tdbg'>"
Response.Write " <td height='25' align='right' class='tdbg5'><strong>标签说明:</strong></td>" & vbCrLf
Response.Write " <td height='25'><INPUT TYPE='text' NAME='lableExplain' value='' id='id' size='15' maxlength='20'> <FONT style='font-size:12px' color='blue'>请在这里填写标签的使用说明方便以后的查找</FONT> </td>"
Response.Write " </tr>"
End If
Select Case ChannelShowType
Case "GetList"
Call GetList
Case "GetPic"
Call GetPic
Case "GetSlide"
Call GetSlide
Case "GetPositionList"
Call GetPositionList
Case "GetSearchResult"
Call GetSearchResult
Case Else
Response.Write "错误的参数命令!"
Response.End
End Select
Response.Write " <tr class='tdbg'>"
Response.Write " <td height='40' colspan='2' align='center'>"
Response.Write " <input name='Title' type='hidden' id='Title' value='" & Title & "'>"
Response.Write " <input name='LabelName' type='hidden' id='LabelName' value='" & LabelName & "'>"
Response.Write " <input name='editLabel' type='hidden' id='editLabel' value='" & editLabel & "'>"
Response.Write " <input name='dChannelID' type='hidden' id='dChannelID' value='" & dChannelID & "'>"
Response.Write " <input name='ModuleType' type='hidden' id='ModuleType' value='" & ModuleType & "'>"
Response.Write " <input name='InsertTemplate' type='hidden' id='InsertTemplate' value='" & InsertTemplate & "'>"
Response.Write " <input name='ChannelShowType' type='hidden' id='ChannelShowType' value='" & ChannelShowType & "'>"
Response.Write " <input name='MakeJS' type='button' id='MakeJS' onclick=""makejs('" & LabelName & "','" & ChannelShowType & "');"" value=' 确 定 '>"
Response.Write " </td>"
Response.Write " </tr>"
Response.Write " </table>"
Response.Write "</form>"
Response.Write "<script language=""JavaScript"" type=""text/JavaScript"">" & vbCrLf
Response.Write "function makejs(LabelName,Type)" & vbCrLf
Response.Write "{" & vbCrLf
If ModuleType <> 8 Then
Response.Write " if (document.myform.ClassID.value==''){" & vbCrLf
Response.Write " alert('" & ChannelShortName & "所属栏目不能指定为外部栏目!');" & vbCrLf
Response.Write " document.myform.ClassID.focus();" & vbCrLf
Response.Write " return false;" & vbCrLf
Response.Write " }" & vbCrLf
End If
Response.Write " var strJS;" & vbCrLf
If editLabel = "" And InsertTemplate = 0 Then
If ModuleType <> 8 Then
Response.Write " if (document.myform.lableExplain.value !=""""){" & vbCrLf
Response.Write " strJS=""{$--""+document.myform.lableExplain.value+""--}"";" & vbCrLf
Response.Write " }else{" & vbCrLf
Response.Write " strJS="""";" & vbCrLf
Response.Write " }" & vbCrLf
Else
Response.Write " strJS="""";" & vbCrLf
End If
Response.Write " strJS+=""<IMG SRC='editor/images/label.gif' BORDER='0' "";" & vbCrLf
Response.Write " strJS+=""zzz='{$""+LabelName+""("";" & vbCrLf
Else
Response.Write " strJS=""{$""+LabelName+""("";" & vbCrLf
End If
Response.Write " switch(Type){" & vbCrLf
Response.Write " case ""GetList"":" & vbCrLf
If ModuleType <> 5 Then
Response.Write " strJS+=document.myform.ChannelID.value;" & vbCrLf
Response.Write " strJS+="",""" & vbCrLf
End If
Call CellNclass
Response.Write " strJS+="",""+document.myform.IncludeChild.checked;" & vbCrLf
Response.Write " strJS+="",""+document.myform.SpecialID.value; " & vbCrLf
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?