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

📄 powereasy.guestbook.asp

📁 个人网站比较简短
💻 ASP
📖 第 1 页 / 共 5 页
字号:
            strTemp = Replace(strTemp, "{$GuestNameType}", GtbGuest)
        End If

        strTemp = Replace(strTemp, "{$GuestTitle}", "  <a href=Guest_Reply.asp?TopicID=" & rsGuest("TopicID") & ">" & rsGuest("GuestTitle") & "</a>")
        strTemp = Replace(strTemp, "{$GuestContentLength}", rsGuest("GuestContentLength") & "")
        strTemp = Replace(strTemp, "{$GuestName}", rsGuest("GuestName") & "")
        strTemp = Replace(strTemp, "{$ReplyNum}", rsGuest("ReplyNum") & "")
        strTemp = Replace(strTemp, "{$Hits}", rsGuest("Hits") & "")
        If rsGuest("LastReplyTime") <> "" Then
            strTemp = Replace(strTemp, "{$GuestTime}", TransformTime(rsGuest("LastReplyTime")))
            strTemp = Replace(strTemp, "{$LastReplyGuest}", rsGuest("LastReplyGuest"))
        ElseIf rsGuest("GuestReplyDatetime") <> "" Then
            strTemp = Replace(strTemp, "{$GuestTime}", TransformTime(rsGuest("GuestReplyDatetime")))
            strTemp = Replace(strTemp, "{$LastReplyGuest}", rsGuest("GuestReplyAdmin"))
        Else
            strTemp = Replace(strTemp, "{$GuestTime}", TransformTime(rsGuest("GuestDatetime")))
            strTemp = Replace(strTemp, "{$LastReplyGuest}", rsGuest("GuestName"))
        End If
        strTemp = Replace(strTemp, "{$GuestID}", rsGuest("GuestID"))
        
        testHTML = testHTML & strTemp

        i = i + 1
        If i >= MaxPerPage Then Exit Do
        rsGuest.MoveNext
    Loop
    testHTML = strBeg & testHTML & strEnd & "<br><iframe with='0' height='0' src='' name='hiddeniframe'></iframe>"

   
    rsGuest.Close
    Set rsGuest = Nothing
    
    GetRepeatDiscussion = testHTML
 
End Function

'=================================================
'函数名:GuestFace()
'作  用:留言心情选择
'参  数:无
'=================================================
Private Function GuestFace()
    Dim i, strHTM
    'For i = 1 To 30
    For i = 1 To 20
        strHTM = strHTM & "<input type='radio' name='GuestFace' value='" & i & "'"
        If i = PE_CLng(WriteFace) Then strHTM = strHTM & " checked"
        strHTM = strHTM & " style='BORDER:0px;width:19;'>"
        strHTM = strHTM & "<img src='" & GImagePath & "face" & i & ".gif' width='19' height='19'>" & vbCrLf
        If i Mod 10 = 0 Then strHTM = strHTM & "<br>"
    Next

    GuestFace = strHTM
End Function

'=================================================
'函数名:ManageRubbishContent()
'作  用:屏蔽垃圾广告子函数
'参  数:无
'=================================================
Private Function ManageRubbishContent(ByVal GuestBook_ManageRubbish, ByVal GuestContent)
    Dim RubbishContent
    RubbishContent = False
    ManageRubbishContent = RubbishContent
    Dim i, obj
    If GuestBook_ManageRubbish = "" Or IsNull(GuestBook_ManageRubbish) Then
        RubbishContent = False
        Exit Function
    End If
    obj = Split(GuestBook_ManageRubbish, "$$$")
    If GuestContent = "" Then Exit Function
    For i = 0 To UBound(obj)
        If Trim(obj(i)) <> "" And InStr(GuestContent, Trim(obj(i))) > 0 Then
            RubbishContent = True
            If RubbishContent Then Exit For
        End If
    Next
    ManageRubbishContent = RubbishContent
End Function
'=================================================
'函数名:GuestContent()
'作  用:留言内容
'参  数:无
'=================================================
Private Function GuestContent()
    Dim strHTM
    strHTM = "<textarea name='GuestContent' id='GuestContent' style='display:none' >" & Server.HTMLEncode(FilterJS(WriteContent)) & "</textarea>" & vbCrLf
    strHTM = strHTM & "<iframe ID='editor' src='../editor.asp?ChannelID=1&ShowType=2&tContentid=GuestContent' frameborder='1' scrolling='no' width='480' height='280' ></iframe>" & vbCrLf
    GuestContent = strHTM
End Function

'=================================================
'函数名:DefaultTemplate()
'作  用:得到默认模板设置,与以前版本兼容
'参  数:strType 页面类别
'=================================================
Private Function DefaultTemplate(strType)
    Dim TemplateType, strTemplate
    TemplateType = Trim(strType)
    
    If TemplateType = "" Or IsNull(TemplateType) Then
        DefaultTemplate = ""
        Exit Function
    End If
    
    Select Case TemplateType
        Case "Index"
            strTemplate = TemplateDiscission("Index") & TemplateGuestBook("Index")
        Case "strWrite"
            strTemplate = TemplateGuestBook("strWrite")
        Case "Reply"
            strTemplate = TemplateGuestBook("Reply")
        Case "Search"
            strTemplate = TemplateDiscission("Search") & TemplateGuestBook("Search")
    End Select
    
    DefaultTemplate = strTemplate
End Function

'=================================================
'函数名:TemplateDiscission()
'作  用:得到讨论区方式默认模板设置
'参  数:strstlye1 页面类别
'=================================================
Private Function TemplateDiscission(strstlye1)
    Dim strTemplate
    strTemplate = ""
    If strstlye1 = "Index" Then
        strTemplate = strTemplate & "     <!--讨论区方式循环显示留言结束-->   【GuestList2(0)】" & vbCrLf
    Else
        strTemplate = strTemplate & "     <!--讨论区方式循环显示留言结束-->   【GuestList2(1)】" & vbCrLf
    End If
    strTemplate = strTemplate & "             【GuestList2_Beg】<table width='100%' class='Guest_border' border='0' cellspacing='1' cellpadding='0' align='center'>" & vbCrLf
    strTemplate = strTemplate & "      <tr class='Guest_title'>" & vbCrLf
    strTemplate = strTemplate & "        <td width='58%' colspan='3'> " & vbCrLf
    strTemplate = strTemplate & "          <div align='center'><b>发言主题</b></div>" & vbCrLf
    strTemplate = strTemplate & "        </td>" & vbCrLf
    strTemplate = strTemplate & "        <td width='10%' nowrap> " & vbCrLf
    strTemplate = strTemplate & "          <div align='center'><b>留言人</b></div>" & vbCrLf
    strTemplate = strTemplate & "        </td>" & vbCrLf
    strTemplate = strTemplate & "        <td width='5%' nowrap> " & vbCrLf
    strTemplate = strTemplate & "          <div align='center'><b>回复</b></div>" & vbCrLf
    strTemplate = strTemplate & "        </td>   " & vbCrLf
    strTemplate = strTemplate & "        <td width='5%' nowrap> " & vbCrLf
    strTemplate = strTemplate & "          <div align='center'><b>阅读</b></div>" & vbCrLf
    strTemplate = strTemplate & "        </td>   " & vbCrLf
    strTemplate = strTemplate & "        <td width='22%' nowrap>  " & vbCrLf
    strTemplate = strTemplate & "          <div align='center'><b>最后回复</b></div>" & vbCrLf
    strTemplate = strTemplate & "        </td>    " & vbCrLf
    strTemplate = strTemplate & "      </tr>【/GuestList2_Beg】" & vbCrLf
    strTemplate = strTemplate & "<tr class='Guest_tdbg'>" & vbCrLf
    strTemplate = strTemplate & "<td width='5%' align='center'>" & vbCrLf
    strTemplate = strTemplate & "  {$GuestFaceShow}" & vbCrLf
    strTemplate = strTemplate & "  </td>" & vbCrLf
    strTemplate = strTemplate & "  <td width='5%'  align='center'>" & vbCrLf
    strTemplate = strTemplate & "{$IsTitlePic}" & vbCrLf
    strTemplate = strTemplate & "  </td><td width='48%' title='点击查看记录具体信息' align='left'>{$GuestTitle}<I><font color=gray>({$GuestContentLength}字)</td>" & vbCrLf
    strTemplate = strTemplate & "  <td width='10%' align='center'>{$GuestName}</td>" & vbCrLf
    strTemplate = strTemplate & "  <td width='5%' align='center'>{$ReplyNum}</td>" & vbCrLf
    strTemplate = strTemplate & "  <td width='5%' align='center'>{$Hits}</td>" & vbCrLf
    strTemplate = strTemplate & "  <td width='22%' align='left'>{$GuestTime}<font class=Channel_font> | </font>{$LastReplyGuest}</td></tr>" & vbCrLf
    strTemplate = strTemplate & "  <tr id='FollowTr{$GuestID}' style='display:none;'><td id='FollowTd{$GuestID}' colspan='7'></td></tr>" & vbCrLf
    strTemplate = strTemplate & "【GuestList2_End】</table>【/GuestList2_End】【/GuestList2】" & vbCrLf
    strTemplate = strTemplate & "     <!--讨论区方式循环显示留言结束-->" & vbCrLf
    TemplateDiscission = strTemplate
End Function

'=================================================
'函数名:TemplateGuestBook()
'作  用:得到留言本方式默认模板设置
'参  数:strstlye2 页面类别
'=================================================
Private Function TemplateGuestBook(strstlye2)
    Dim strTemplate
    strTemplate = ""
    strTemplate = strTemplate & "                     <!--留言本方式循环显示留言开始-->" & vbCrLf
    If strstlye2 = "Index" Then
        strTemplate = strTemplate & "     【GuestList1(0)】" & vbCrLf
    ElseIf strstlye2 = "strWrite" Then
        strTemplate = strTemplate & "     【GuestList1(1)】" & vbCrLf
    ElseIf strstlye2 = "Reply" Then
        strTemplate = strTemplate & "     【GuestList1(2)】" & vbCrLf
    Else
        strTemplate = strTemplate & "     【GuestList1(3)】" & vbCrLf
    End If
    strTemplate = strTemplate & "          <table width='100%' border='0' cellpadding='0' cellspacing='1' class='Guest_border'>" & vbCrLf
    strTemplate = strTemplate & "        <tr>" & vbCrLf
    strTemplate = strTemplate & "          <td align='center' valign='top'>" & vbCrLf
    strTemplate = strTemplate & "            <table width='100%' border='0' cellspacing='0' cellpadding='0' class='Guest_title'>" & vbCrLf
    strTemplate = strTemplate & "              <tr>" & vbCrLf
    strTemplate = strTemplate & "                <td>" & vbCrLf
    strTemplate = strTemplate & "{$IsTitlePic}<strong>{$GuestType}:</strong>{$GuestTitle}" & vbCrLf
    strTemplate = strTemplate & "                </td>" & vbCrLf
    strTemplate = strTemplate & "                <td width='180'>" & vbCrLf
    strTemplate = strTemplate & "                  <img src='{$InstallDir}Images/posttime.gif' width='11' height='11' align='absmiddle'>:{$GuestTime}" & vbCrLf
    strTemplate = strTemplate & "                </td>" & vbCrLf
    strTemplate = strTemplate & "              </tr>" & vbCrLf
    strTemplate = strTemplate & "            </table>" & vbCrLf
    strTemplate = strTemplate & "          </td>" & vbCrLf
    strTemplate = strTemplate & "        </tr>" & vbCrLf
    strTemplate = strTemplate & "        <tr>" & vbCrLf
    strTemplate = strTemplate & "          <td align='center' height='153' valign='top' class='Guest_tdbg'>" & vbCrLf
    strTemplate = strTemplate & "            <table width='100%' border='0' cellpadding='0' cellspacing='3'>" & vbCrLf
    strTemplate = strTemplate & "              <tr>" & vbCrLf
    strTemplate = strTemplate & "                <td width='130' align='center' height='130' valign='top'>" & vbCrLf
    strTemplate = strTemplate & "{$GuestHead}<br>" & vbCrLf
    strTemplate = strTemplate & "                        <br>" & vbCrLf
    strTemplate = strTemplate & "【{$GuestNameType}】<br>{$GuestName}                </td>" & vbCrLf
    strTemplate = strTemplate & "                <td align='center' height='153' width='1' class='Guest_tdbg_1px'></td>" & vbCrLf
    strTemplate = strTemplate & "                <td>" & vbCrLf
    strTemplate = strTemplate & "                  <table width='100%' border='0' cellpadding='6' cellspacing='0' height='125' style='TABLE-LAYOUT: fixed'>" & vbCrLf
    strTemplate = strTemplate & "                    <tr>" & vbCrLf
    strTemplate = strTemplate & "                      <td align='left' valign='top'>{$GuestFaceShow}【ContentShow】" & vbCrLf
    strTemplate = strTemplate & "                     {$IsHiddenShow}" & vbCrLf
    strTemplate = strTemplate & "{$GuestContentShow}" & vbCrLf
    strTemplate = strTemplate & "【LastReplyShow】<table width='98%' align='right'  cellpadding='5' cellspacing='0' class='Guest_border2'>" & vbCrLf
    strTemplate = strTemplate & "  <tr><td align='left' valign='top' class='Guest_ReplyUser'> 回复主题:{$LastReplyTitle}     回复人:{$LastReplyGuest}</td>       </tr>       <tr>     <td colspan=2>" & vbCrLf
    strTemplate = strTemplate & "{$LastReplyContent}</td></tr></table>【/LastReplyShow】                     </td>" & vbCrLf
    strTemplate = strTemplate & "                    </tr>" & vbCrLf
    strTemplate = strTemplate & "                    <tr>" & vbCrLf
    strTemplate = strTemplate & "                      <td align='left' valign='bottom'>" & vbCrLf
    strTemplate = strTemplate & "                     【AdminReplyShow】" & vbCrLf
    strTemplate = strTemplate & "                                             <table width='100%' border='0' cellspacing='0' cellpadding='2'>" & vbCrLf
    strTemplate = strTemplate & "                          <tr>" & vbCrLf
    strTemplate = strTemplate & "                            <td height='1' class='Guest_tdbg_1px'></td>" & vbCrLf
    strTemplate = strTemplate & "                          </tr>" & vbCrLf
    strTemplate = strTemplate & "                          <tr>" & vbCrLf
    strTemplate = strTemplate & "                            <td valign='top'>" & vbCrLf
    strTemplate = strTemplate & "                              <table width='100%' border='0' cellpadding='0' cellspacing='0' style='TABLE-LAYOUT: fixed' class='Guest_border2'>" & vbCrLf
    strTemplate = strTemplate & "                                <tr>" & vbCrLf
    strTemplate = strTemplate & "                                  <td class='Guest_ReplyAdmin'> 管理员[{$ReplyAdmin}]回复:</td>" & vbCrLf
    strTemplate = strTemplate & "                                </tr>" & vbCrLf
    strTemplate = strTemplate & "                                <tr>" & vbCrLf
    strTemplate = strTemplate & "                                  <td valign='bottom'>{$AdminReplyContent}    回复时间:" & vbCrLf
    strTemplate = strTemplate & "{$AdminReplyTime}</td>" & vbCrLf
    strTemplate = strTemplate & "                                </tr>" & vbCrLf
    strTemplate = strTemplate & "                              </table>" & vbCrLf
    strTemplate = strTemplate & "                            </td>" & vbCrLf
    strTemplate = strTemplate & "                          </tr>" & vbCrLf
    strTemplate = strTemplate & "                        </table>【/AdminReplyShow】" & vbCrLf
    strTemplate = strTemplate & "                       " & vbCrLf
    strTemplate = strTemplate & "                      【/ContentShow】</td>" & vbCrLf
    strTemplate = strTemplate & "                    </tr>" & vbCrLf
    strTemplate = strTemplate & "                  </table>" & vbCrLf
    strTemplate = strTemplate & "                  <table width='100%' height='1' border='0' cellpadding='0' cellspacing='0' class='Guest_tdbg_1px'>" & vbCrLf
    strTemplate = strTemplate & "                    <tr>" & vbCrLf
    strTemplate = strTemplate & "                      <td><

⌨️ 快捷键说明

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