📄 delpoll.asp
字号:
<% Option Explicit %>
<!--#include file="conn.asp" -->
<%
Response.Buffer = True
Dim lngTopicID
Dim intForumID
Dim lngPollID
Dim strMode
Dim intPollLoopCounter
Dim strPollQuestion
Dim blnMultipleVotes
Dim blnPollNoReply
Dim strPollChoice
If bannedIP() Then
Set rsConn = Nothing
adoCon.Close
Set adoCon = Nothing
Response.Redirect("nopermission.asp?M=IP")
End If
lngTopicID = CLng(Request("tid"))
If lngTopicID = "" Then
Set rsConn = Nothing
adoCon.Close
Set adoCon = Nothing
Response.Redirect("index.asp")
End If
strSQL = "SELECT timestopic.bbsid, timestopic.pollid "
strSQL = strSQL & "FROM timestopic "
strSQL = strSQL & "WHERE timestopic.topicid = " & lngTopicID & ";"
rsConn.CursorType = 2
rsConn.LockType = 3
rsConn.Open strSQL, adoCon
If NOT rsConn.EOF Then
intForumID = CInt(rsConn("bbsid"))
lngPollID = CLng(rsConn("pollid"))
End If
If blnAdmin = False Then blnModerator = isModerator(intForumID, intGroupID)
If (blnAdmin = True OR blnModerator = True) AND lngPollID > 0 Then
rsConn.Fields("pollid") = 0
rsConn.Update
strSQL = "DELETE FROM timeschoice WHERE timeschoice.pollid=" & lngPollID & ";"
adoCon.Execute(strSQL)
strSQL = "DELETE FROM timespoll WHERE timespoll.pollid=" & lngPollID & ";"
adoCon.Execute(strSQL)
End If
rsConn.Close
Set rsConn = Nothing
adoCon.Close
Set adoCon = Nothing
%>
<html>
<head>
<script language="JavaScript">
window.opener.location.href = "post.asp?tid=<% = lngTopicID %>"
window.close();
</script>
</head>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -