📄 getstriparticle.asp
字号:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<%option explicit%>
<!--#include file="../../../Conn.asp"-->
<!--#include file="../../../SysCls/KS_CommonCls.asp"-->
<!--#include file="../../Inc/Session.asp"-->
<%
'===================================================================================================================
'软件名称:科汛网站管理系统
'当前版本:科汛网站管理系统 V2.2 SP2 Free
'Copyright (C) 2006-2008 Kesion.Com All rights reserved.
'产品咨询QQ:9537636,41904294
'技术支持QQ:111394,54004407
'程序版权:科汛网络
'程序开发:科汛网络开发组(总策划:林文仲)
'E-Mail :kesioncms@hotmail.com webmaster@kesion.com
'官方网站:http://www.kesion.com
'演示站点:http://test.kesion.com
'郑重声明:
' ①、免费版本请在程序首页保留版权信息,并做上本站LOGO友情连接,商业版本无此要求;
' ②、任何个人或组织不得在授权允许的情况下删除、修改、拷贝本软件及其他副本上一切关于版权的信息;
' ③、科汛网络保留此软件的法律追究权利
'===================================================================================================================
Dim KSCls
Set KSCls = New GetStripArticle
KSCls.Execute()
Set KSCls = Nothing
Class GetStripArticle
Private KSCMS
Private Sub Class_Initialize()
Set KSCMS=New CommonCls
End Sub
Private Sub Class_Terminate()
Call KSCMS.CloseConn()
Set KSCMS=Nothing
End Sub
'主体部分
Public Sub Execute()
Dim InstallDir, CurrPath, FolderID, LabelContent, LabelContentArr, Action, LabelID, Str, Descript, LabelFlag
Dim ClassID, IncludeSubClass, OpenType, StripArticleNumber, RowHeight, TitleLen, ColNumber, NavType, Navi, SplitPic, TitleCss
FolderID = Request("FolderID")
CurrPath = KSCMS.GetConfig("UpFilesDir")
InstallDir = KSCMS.GetConfig("InstallDir")
CurrPath = Left(CurrPath, Len(CurrPath) - 1)
If InstallDir = "/" Then CurrPath = "/" & CurrPath
'判断是否编辑
LabelID = Trim(Request.QueryString("LabelID"))
If LabelID = "" Then
ClassID = "0"
Action = "Add"
Else
Action = "Edit"
Dim LabelRS, LabelName
Set LabelRS = Server.CreateObject("Adodb.Recordset")
LabelRS.Open "Select * From KS_Label Where ID='" & LabelID & "'", Conn, 1, 1
If LabelRS.EOF And LabelRS.BOF Then
LabelRS.Close
Set LabelRS = Nothing
Response.Write ("<Script>alert('参数传递出错!');window.close();</Script>")
Response.End
End If
LabelName = Replace(Replace(LabelRS("LabelName"), "{LB_", ""), "}", "")
FolderID = LabelRS("FolderID")
Descript = LabelRS("Description")
LabelContent = LabelRS("LabelContent")
LabelFlag = LabelRS("LabelFlag")
LabelRS.Close
Set LabelRS = Nothing
LabelContent = Replace(Replace(LabelContent, "{$GetStripArticle(", ""), ")}", "")
LabelContent = Replace(LabelContent, """", "") '注:去除左右双引号"
LabelContentArr = Split(LabelContent, ",")
ClassID = LabelContentArr(0)
IncludeSubClass = CBool(LabelContentArr(1))
ColNumber = LabelContentArr(2)
OpenType = LabelContentArr(3)
StripArticleNumber = LabelContentArr(4)
RowHeight = LabelContentArr(5)
TitleLen = LabelContentArr(6)
NavType = LabelContentArr(7)
Navi = LabelContentArr(8)
SplitPic = LabelContentArr(9)
TitleCss = LabelContentArr(10)
End If
If StripArticleNumber = "" Then StripArticleNumber = 1
If RowHeight = "" Then RowHeight = 20
If TitleLen = "" Then TitleLen = 30
If ColNumber = "" Then ColNumber = 1
Response.Write "<html>"
Response.Write "<head>"
Response.Write "<meta http-equiv=""Content-Type"" content=""text/html; charset=gb2312"">"
Response.Write "<link href=""../../Inc/ModeWindow.css"" rel=""stylesheet"">"
Response.Write "<script src=""../LabelJs/GetStripArticle.JS"" language=""JavaScript""></script>"
Response.Write "<script src=""../../JS/Common.js"" language=""JavaScript""></script>"
Response.Write "</head>"
Response.Write "<body topmargin=""0"" leftmargin=""0"" scroll=no>"
Response.Write "<div align=""center"">"
Response.Write "<form method=""post"" name=""myform"" action=""AddLabelSave.asp"">"
Response.Write " <input type=""hidden"" name=""LabelContent"">"
Response.Write " <input type=""hidden"" name=""LabelFlag"" value=""" & LabelFlag & """>"
Response.Write " <input type=""hidden"" name=""Action"" value=""" & Action & """>"
Response.Write " <input type=""hidden"" name=""LabelID"" value=""" & LabelID & """>"
Response.Write " <input type=""hidden"" name=""FileUrl"" value=""GetStripArticle.asp"">"
Response.Write " <br>"
Response.Write KSCMS.ReturnLabelInfo(LabelName, FolderID, Descript)
Response.Write " <br>"
Response.Write " <table width=""96%"" border=""0"" cellspacing=""0"" cellpadding=""0"">"
Response.Write " <tr>"
Response.Write " <td>"
Response.Write " <FIELDSET align=center><LEGEND align=left>今日头条文章标签属性设置</LEGEND>"
Response.Write " <table width=""100%"" border=""0"" align=""center"" cellpadding=""0"" cellspacing=""0"">"
Response.Write " <tr>"
Response.Write " <td width=""50%"" height=""30"">选择栏目"
Response.Write " <select class=""textbox"" style=""width:70%;"" name=""ClassList"" id=""select"" onChange=""SetLabelFlag(this)"">"
Response.Write " <option selected value=""-1"" style=""color:red"">- 当前栏目(通用)-</option>"
If ClassID = "0" Then
Response.Write ("<option value=""0"" selected>- 不指定栏目 -</option>")
Else
Response.Write ("<option value=""0"">- 不指定栏目 -</option>")
End If
Response.Write KSCMS.ReturnTree(ClassID, 1)
Response.Write "</select> </td>"
Response.Write " <td height=""30""> <div align=""left"">"
If IncludeSubClass = True Or LabelID = "" Then
Str = " Checked"
Else
Str = ""
End If
Response.Write ("<input name=""IncludeSubClass"" type=""checkbox"" id=""IncludeSubClass"" value=""true""" & Str & ">")
Response.Write " 允许包含子栏目</div></td>"
Response.Write " </tr>"
Response.Write " <tr>"
Response.Write " <td height=""30"">排列列数"
Response.Write " <input class=""textbox"" type=""text"" onBlur=""CheckNumber(this,'排列列数');"" style=""width:70%;"" value=""" & ColNumber & """ name=""ColNumber"">"
Response.Write " </td>"
Response.Write " <td height=""30"">"
Response.Write KSCMS.ReturnOpenTypeStr(OpenType)
Response.Write " </td>"
Response.Write " </tr>"
Response.Write " <tr>"
Response.Write " <td height=""30"">文章数量"
Response.Write " <input name=""StripArticleNumber"" class=""textbox"" type=""text"" id=""StripArticleNumber"" style=""width:70%;"" onBlur=""CheckNumber(this,'文章数量');"" value=""" & StripArticleNumber & """></td>"
Response.Write " <td height=""30"">文章行距"
Response.Write " <input name=""RowHeight"" class=""textbox"" type=""text"" id=""RowHeight"" style=""width:70%;"" onBlur=""CheckNumber(this,'文章行距');"" value=""" & RowHeight & """></td>"
Response.Write " </tr>"
Response.Write " <tr>"
Response.Write " <td height=""30"">标题字数"
Response.Write " <input name=""TitleLen"" class=""textbox"" onBlur=""CheckNumber(this,'标题字数');"" type=""text"" style=""width:70%;"" value=""" & TitleLen & """>"
Response.Write " </td>"
Response.Write " <td height=""30""><font color=""#FF0000"">一个汉字=两个英文字符</font></td>"
Response.Write " </tr>"
Response.Write " <tr>"
Response.Write " <td height=""30"">导航类型"
Response.Write " <select name=""NavType"" class=""textbox"" style=""width:70%;"" onchange=""SetNavStatus()"">"
If LabelID = "" Or CStr(NavType) = "0" Then
Response.Write ("<option value=""0"" selected>文字导航</option>")
Response.Write ("<option value=""1"">图片导航</option>")
Else
Response.Write ("<option value=""0"">文字导航</option>")
Response.Write ("<option value=""1"" selected>图片导航</option>")
End If
Response.Write " </select></td>"
Response.Write " <td height=""30"">"
If LabelID = "" Or CStr(NavType) = "0" Then
Response.Write ("<div align=""left"" id=""NavWord""> ")
Response.Write ("<input type=""text"" class=""textbox"" name=""TxtNavi"" style=""width:70%;"" value=""" & Navi & """>支持HTML语法")
Response.Write ("</div>")
Response.Write ("<div align=""left"" id=NavPic style=""display:none""> ")
Response.Write ("<input type=""text"" class=""textbox"" readonly style=""width:45%;"" id=""NaviPic"" name=""NaviPic"">")
Response.Write ("<input type=""button"" onClick=""OpenThenSetValue('../../Dialog/SelectPic.asp?CurrPath=" & CurrPath & "&ShowVirtualPath=true',550,290,window,document.myform.NaviPic);"" name=""Submit3"" value=""选择图片..."">")
Response.Write (" <span style=""cursor:hand;color:green;"" onclick=""javascript:document.myform.NaviPic.value='';"" onmouseover=""this.style.color='red'"" onMouseOut=""this.style.color='green'"">清除</span>")
Response.Write ("</div>")
Else
Response.Write ("<div align=""left"" id=""NavWord"" style=""display:none""> ")
Response.Write ("<input type=""text"" class=""textbox"" name=""TxtNavi"" style=""width:70%;"">支持HTML语法")
Response.Write ("</div>")
Response.Write ("<div align=""left"" id=NavPic> ")
Response.Write ("<input type=""text"" class=""textbox"" readonly style=""width:45%;"" id=""NaviPic"" name=""NaviPic"" value=""" & Navi & """>")
Response.Write ("<input type=""button"" onClick=""OpenThenSetValue('../../Dialog/SelectPic.asp?CurrPath=" & CurrPath & "&ShowVirtualPath=true',550,290,window,document.myform.NaviPic);"" name=""Submit3"" value=""选择图片..."">")
Response.Write (" <span style=""cursor:hand;color:green;"" onclick=""javascript:document.myform.NaviPic.value='';"" onmouseover=""this.style.color='red'"" onMouseOut=""this.style.color='green'"">清除</span>")
Response.Write ("</div>")
End If
Response.Write " </td>"
Response.Write " </tr>"
Response.Write " <tr>"
Response.Write " <td height=""30"" colspan=""2"">分隔图片"
Response.Write " <input name=""SplitPic"" class=""textbox"" type=""text"" id=""SplitPic"" style=""width:63%;"" value=""" & SplitPic & """ readonly>"
Response.Write " <input name=""SubmitPic"" onClick=""OpenThenSetValue('../../Dialog/SelectPic.asp?CurrPath=" & CurrPath & "&ShowVirtualPath=true',550,290,window,document.myform.SplitPic);"" type=""button"" id=""SubmitPic"" value=""选择图片..."">"
Response.Write " <span style=""cursor:hand;color:green;"" onclick=""javascript:document.myform.SplitPic.value='';"" onmouseover=""this.style.color='red'"" onMouseOut=""this.style.color='green'"">清除</span>"
Response.Write " </td>"
Response.Write " </tr>"
Response.Write " <tr>"
Response.Write " <td height=""30"">标题样式"
Response.Write " <input name=""TitleCss"" class=""textbox"" type=""text"" id=""TitleCss"" style=""width:70%;"" value=""" & TitleCss & """></td>"
Response.Write " <td height=""30""><font color=""#FF0000"">已定义的CSS ,要有一定的网页设计基础</font></td>"
Response.Write " </tr>"
Response.Write " </table>"
Response.Write " </FIELDSET>"
Response.Write " </td></tr>"
Response.Write " </table>"
Response.Write " <table width=""96%"" border=""0"" cellpadding=""0"" cellspacing=""0"">"
Response.Write " <tr>"
Response.Write " <td height=""30"" colspan=""2""> <div align=""right"">"
Response.Write " <table width=""100%"" border=""0"" cellspacing=""0"" cellpadding=""0"">"
Response.Write " <tr>"
Response.Write " <td> </td>"
Response.Write " <td> </td>"
Response.Write " <td> </td>"
Response.Write " <td> </td>"
Response.Write " </tr>"
Response.Write " <tr>"
Response.Write " <td> </td>"
Response.Write " <td width=""100""> <div align=""center"">"
Response.Write " <input name=""SubmitBtn"" type=""button"" onClick=""InsertScriptFun()"" id=""Submitsss4"" value="" 确 定 "">"
Response.Write " </div></td>"
Response.Write " <td width=""100""> <div align=""center"">"
Response.Write " <input type=""button"" onClick=""window.close();"" name=""Submit2"" value="" 取 消 "">"
Response.Write " </div></td>"
Response.Write " <td> </td>"
Response.Write " </tr>"
Response.Write " </table>"
Response.Write " </div></td>"
Response.Write " </tr>"
Response.Write " </table>"
Response.Write " <br>"
Response.Write " <table width=""92%"" height=""15"" border=""0"" align=""center"" cellpadding=""0"" cellspacing=""0"">"
Response.Write " <tr>"
Response.Write " <td height=""25""><strong>附加说明:</strong>1<strong>.</strong>此标签作用:显示最新添加且具有头条属性的文章"
Response.Write " <a href=""#"" onclick=""javascript:open('../View/ViewStrip.htm','new','left=250,top=50,width=400,height=180')"">点此预览</a></td>"
Response.Write " </tr>"
Response.Write " <tr>"
Response.Write " <td height=""25""> 2.当选择栏目为<font color=""#FF0000""> "当前栏目(通用)"</font>,则此标签在网站首页、频道首页、栏目、内容页通用</td>"
Response.Write " </tr>"
Response.Write " </table>"
Response.Write " </form>"
Response.Write "</div>"
Response.Write "</body>"
Response.Write "</html>"
End Sub
End Class
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -