⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 powereasy.common.manage.asp

📁 个人网站比较简短
💻 ASP
📖 第 1 页 / 共 3 页
字号:
    Response.Write "         return false;" & vbCrLf
    Response.Write " }" & vbCrLf
    Response.Write " else if(document.myform.Action.value=='ConfirmDel'){" & vbCrLf
    Response.Write "     if(confirm('确定要彻底删除选中的" & ItemName & "吗?彻底删除后将不能恢复!'))" & vbCrLf
    Response.Write "         return true;" & vbCrLf
    Response.Write "     else" & vbCrLf
    Response.Write "         return false;" & vbCrLf
    Response.Write " }" & vbCrLf
    Response.Write " else if(document.myform.Action.value=='ClearRecyclebin'){" & vbCrLf
    Response.Write "     if(confirm('确定要清空回收站?一旦清空将不能恢复!'))" & vbCrLf
    Response.Write "         return true;" & vbCrLf
    Response.Write "     else" & vbCrLf
    Response.Write "         return false;" & vbCrLf
    Response.Write " }" & vbCrLf
    Response.Write " else if(document.myform.Action.value=='DelFromSpecial'){" & vbCrLf
    Response.Write "     if(confirm('确定要将选中的" & ItemName & "从其所属专题中删除吗?操作成功后" & ItemName & "将不属于任何专题。'))" & vbCrLf
    Response.Write "         return true;" & vbCrLf
    Response.Write "     else" & vbCrLf
    Response.Write "         return false;" & vbCrLf
    Response.Write " }" & vbCrLf
    Response.Write "}" & vbCrLf
    Response.Write "</SCRIPT>" & vbCrLf
End Sub

Sub ShowContentManagePath(RootName)
    Response.Write "您现在的位置:&nbsp;" & ChannelName & "管理&nbsp;&gt;&gt;&nbsp;<a href='" & FileName & "'>" & RootName & "</a>&nbsp;&gt;&gt;&nbsp;"
    If ClassID > 0 Then
        If ParentID > 0 Then
            Dim sqlPath, rsPath
            sqlPath = "select ClassID,ClassName from PE_Class where ClassID in (" & ParentPath & ") order by Depth"
            Set rsPath = Conn.Execute(sqlPath)
            Do While Not rsPath.EOF
                Response.Write "<a href='" & FileName & "&ClassID=" & rsPath(0) & "'>" & rsPath(1) & "</a>&nbsp;&gt;&gt;&nbsp;"
                rsPath.MoveNext
            Loop
            rsPath.Close
            Set rsPath = Nothing
        End If
        Response.Write "<a href='" & FileName & "&ClassID=" & ClassID & "'>" & ClassName & "</a>&nbsp;&gt;&gt;&nbsp;"
    End If
    If ManageType = "My" Then
        Response.Write "<font color=red>" & AdminName & "</font> 添加的" & ChannelShortName & ""
    Else
        If Keyword = "" Then
            Select Case Status
            Case -2
                Response.Write "退稿"
            Case -1
                Response.Write "草稿"
            Case 0
                Response.Write "待审核的" & ChannelShortName & "!"
            Case 1
                Response.Write "已审核的" & ChannelShortName & "!"
            Case Else
                Response.Write "所有" & ChannelShortName & "!"
            End Select
        Else
            Select Case strField
            Case "ID"
                Response.Write "ID等于" & Keyword & "</font> "
            Case "Title"
                Response.Write "标题中含有 <font color=red>" & Keyword & "</font> "
            Case "Content"
                Response.Write "内容中含有 <font color=red>" & Keyword & "</font> "
            Case "Author"
                Response.Write "作者姓名中含有 <font color=red>" & Keyword & "</font> "
            Case "Inputer"
                Response.Write "<font color=red>" & Keyword & "</font> 添加"
            Case "Editor"
                Response.Write "<font color=red>" & Keyword & "</font> 审核"
            Case "Keyword"
                Response.Write "关键字为 <font color=red>" & Keyword & "</font> "
            Case "UpdateTime"
                Response.Write "更新时间为 <font color=red>" & Keyword & "</font> "
            Case "SoftName", "PhotoName"
                Response.Write "名称中含有 <font color=red>" & Keyword & "</font> "
            Case "SoftIntro", "PhotoIntro"
                Response.Write "内容中含有 <font color=red>" & Keyword & "</font> "
            Case Else
                Response.Write "名称中含有 <font color=red>" & Keyword & "</font> "
            End Select
            Select Case Status
            Case -2
                Response.Write "的退稿"
            Case -1
                Response.Write "的草稿"
            Case 0
                Response.Write "并且未审核的" & ChannelShortName & "!"
            Case 1
                Response.Write "并且已审核的" & ChannelShortName & "!"
            Case Else
                Response.Write "的" & ChannelShortName & "!"
            End Select
        End If
    End If
End Sub

'**************************************************
'函数名:GetRootClass
'作  用:显示栏目标题栏
'参  数:ChannelID ---- 频道ID
'        RootID ---- 根栏目ID
'        FileName ---- 栏目文件名
'返回值:栏目标题栏
'**************************************************
Public Function GetRootClass()
    Dim sqlRoot, rsRoot, strRoot
    sqlRoot = "select ClassID,ClassName,RootID,Child from PE_Class where ChannelID=" & ChannelID & " and ParentID=0 and ClassType=1 order by RootID"
    Set rsRoot = Conn.Execute(sqlRoot)
    If rsRoot.BOF And rsRoot.EOF Then
        strRoot = "还没有任何栏目,请首先添加栏目。"
    Else
        strRoot = "|&nbsp;"
        Do While Not rsRoot.EOF
            If rsRoot(2) = RootID Then
                strRoot = strRoot & "<a href='" & FileName & "&ClassID=" & rsRoot(0) & "'><font color=red>" & rsRoot(1) & "</font></a> | "
            Else
                strRoot = strRoot & "<a href='" & FileName & "&ClassID=" & rsRoot(0) & "'>" & rsRoot(1) & "</a> | "
            End If
            rsRoot.MoveNext
        Loop
    End If
    rsRoot.Close
    Set rsRoot = Nothing
    GetRootClass = strRoot
End Function

'**************************************************
'函数名:GetChild_Root
'作  用:显示栏目子栏目标题栏
'参  数:ChannelID ---- 频道ID
'        RootID ---- 根栏目ID
'        ClassID ---- 栏目ID
'        ParentPath ---- 父路径
'        Depth ---- 栏目深度
'        FileName ---- 栏目文件名
'返回值:子栏目标题栏
'**************************************************
Public Function GetChild_Root()
    Dim sqlChild, rsChild, arrParentPath, isCurrent, strChild, i
    If RootID <= 0 Then
        GetChild_Root = ""
        Exit Function
    End If
    sqlChild = "select ClassID,ClassName,Child from PE_Class where ChannelID=" & ChannelID & " and Depth=1 and RootID=" & RootID & " order by OrderID"
    Set rsChild = Conn.Execute(sqlChild)
    If Not (rsChild.BOF And rsChild.EOF) Then
        i = 1
        arrParentPath = Split(ParentPath, ",")
        strChild = "<tr class='tdbg'><td>"
        Do While Not rsChild.EOF
            If Depth <= 1 Then
                If rsChild(0) = ClassID Then
                    isCurrent = True
                Else
                    isCurrent = False
                End If
            Else
                If PE_CLng(arrParentPath(2)) = rsChild(0) Then
                    isCurrent = True
                Else
                    isCurrent = False
                End If
            End If
            If isCurrent = True Then
                strChild = strChild & "&nbsp;&nbsp;<a href='" & FileName & "&ClassID=" & rsChild(0) & "'><font color='red'>" & rsChild(1) & "</font></a>"
            Else
                strChild = strChild & "&nbsp;&nbsp;<a href='" & FileName & "&ClassID=" & rsChild(0) & "'>" & rsChild(1) & "</a>"
            End If
            If rsChild(2) > 0 Then
                strChild = strChild & "(" & rsChild(2) & ")"
            End If
            If i Mod 8 = 0 Then
                strChild = strChild & "<br>"
            Else
                strChild = strChild & "&nbsp;&nbsp;"
            End If
            rsChild.MoveNext
            i = i + 1
        Loop
        strChild = strChild & "</td></tr>"
    End If
    rsChild.Close
    Set rsChild = Nothing
    GetChild_Root = strChild
End Function

Function GetSpecial_Option(SpecialID)
    Dim sqlSpecial, rsSpecial, strOption, strOptionTemp
    sqlSpecial = "select ChannelID,SpecialID,SpecialName,OrderID from PE_Special where ChannelID=0 or ChannelID=" & ChannelID & "   order by ChannelID,OrderID"
    Set rsSpecial = Conn.Execute(sqlSpecial)
    Do While Not rsSpecial.EOF
        If rsSpecial("ChannelID") > 0 Then
            strOptionTemp = rsSpecial("SpecialName") & "(本频道)"
        Else
            strOptionTemp = rsSpecial("SpecialName") & "(全站)"
        End If
        If FoundInArr(SpecialID, rsSpecial("SpecialID"), ",") = True Then
            strOption = strOption & "<option value='" & rsSpecial("SpecialID") & "' selected>" & strOptionTemp & "</option>"
        Else
            strOption = strOption & "<option value='" & rsSpecial("SpecialID") & "'>" & strOptionTemp & "</option>"
        End If
        rsSpecial.MoveNext
    Loop
    rsSpecial.Close
    Set rsSpecial = Nothing
    GetSpecial_Option = strOption
End Function

'**************************************************
'函数名:GetStars
'作  用:显示等级★数量
'参  数:Stars ---- 项目名称
'返回值:下拉菜单数据
'**************************************************
Public Function GetStars(Stars)
    Dim strTemp
    strTemp = strTemp & "<option value='5'"
    If Stars = 5 Then strTemp = strTemp & " selected"
    strTemp = strTemp & ">★★★★★</option>"
    strTemp = strTemp & "<option value='4'"
    If Stars = 4 Then strTemp = strTemp & " selected"
    strTemp = strTemp & ">★★★★</option>"
    strTemp = strTemp & "<option value='3'"
    If Stars = 3 Then strTemp = strTemp & " selected"
    strTemp = strTemp & ">★★★</option>"
    strTemp = strTemp & "<option value='2'"
    If Stars = 2 Then strTemp = strTemp & " selected"
    strTemp = strTemp & ">★★</option>"
    strTemp = strTemp & "<option value='1'"
    If Stars = 1 Then strTemp = strTemp & " selected"
    strTemp = strTemp & ">★</option>"
    strTemp = strTemp & "<option value='0'"
    If Stars = 0 Then strTemp = strTemp & " selected"
    strTemp = strTemp & ">无</option>"
    GetStars = strTemp
End Function

'**************************************************
'函数名:GetAuthorList
'作  用:显示作者
'参  数:ChannelID ---- 频道ID
'        UserName ---- 用户名称
'返回值:【未知】【佚名】【管理员】【更多】
'**************************************************
Public Function GetAuthorList(FilePrefix, ChannelID, UserName)
    Dim Author, strAuthorList

    Author = Trim(Session("Author"))
    Dim strDefAuthor, strUnKnowAuthor
    strDefAuthor = XmlText("BaseText", "DefAuthor", "佚名")
    strUnKnowAuthor = XmlText("BaseText", "UnKnowAuthor", "未知")

    strAuthorList = "<font color='blue'><="
    strAuthorList = strAuthorList & "【<font color='green' onclick=""document.myform.Author.value='" & strDefAuthor & "'"" style=""cursor:hand;"">" & strDefAuthor & "</font>】"
    strAuthorList = strAuthorList & "【<font color='green' onclick=""document.myform.Author.value='" & strUnKnowAuthor & "'"" style=""cursor:hand;"">" & strUnKnowAuthor & "</font>】"
    strAuthorList = strAuthorList & "【<font color='green' onclick=""document.myform.Author.value='" & UserName & "'"" style=""cursor:hand;"">" & UserName & "</font>】"
    If Author <> "" And Author <> strDefAuthor And Author <> strUnKnowAuthor And Author <> UserName Then
        strAuthorList = strAuthorList & "【<font color='green' onclick=""document.myform.Author.value='" & FilterJS(Replace(Author, "'", "")) & "'"" style=""cursor:hand;"">" & FilterJS(Author) & "</font>】"
    End If
    strAuthorList = strAuthorList & "【<font color='green' onclick=""window.open('" & FilePrefix & "_SourceList.asp?TypeSelect=AuthorList&ChannelID=" & ChannelID & "', 'AuthorList', 'width=600,height=450,resizable=0,scrollbars=yes');"" style=""cursor:hand;"">更多</font>】"
    strAuthorList = strAuthorList & "</font>"
    GetAuthorList = strAuthorList
End Function

'**************************************************
'函数名:GetCopyFromList
'作  用:显示来源
'参  数:FilePrefix ----访问身份 Admin,User
'        ChannelID ---- 频道ID
'返回值:<=【本站原创】【更多】
'**************************************************
Public Function GetCopyFromList(FilePrefix, ChannelID)
    Dim CopyFrom, strCopyFromList
    CopyFrom = Trim(Session("CopyFrom"))
    Dim strDefCopyFrom
    strDefCopyFrom = XmlText("BaseText", "DefCopyFrom", "本站原创")

    strCopyFromList = "<font color='blue'><="
    strCopyFromList = strCopyFromList & "【<font color='green' onclick=""document.myform.CopyFrom.value='" & strDefCopyFrom & "'"" style=""cursor:hand;"">" & strDefCopyFrom & "</font>】"
    If CopyFrom <> "" And CopyFrom <> strDefCopyFrom Then
        strCopyFromList = strCopyFromList & "【<font color='green' onclick=""document.myform.CopyFrom.value='" & FilterJS(Replace(CopyFrom, "'", "")) & "'"" style=""cursor:hand;"">" & FilterJS(CopyFrom) & "</font>】"
    End If
    strCopyFromList = strCopyFromList & "【<font color='green' onclick=""window.open('" & FilePrefix & "_SourceList.asp?TypeSelect=CopyFromList&ChannelID=" & ChannelID & "', 'CopyFromList', 'width=600,height=450,resizable=0,scrollbars=yes');"" style=""cursor:hand;"">更多</font>】"
    strCopyFromList = strCopyFromList & "</font>"
    GetCopyFromList = strCopyFromList
End Function

'**************************************************
'函数名:GetKeywordList
'作  用:显示关键字
'参  数:FilePrefix ----访问身份 Admin,User

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -