📄 admin_web_wiz_forums_configuration.asp
字号:
<% @ Language=VBScript %>
<% Option Explicit %>
<!--#include file="admin_common.asp" -->
<%
'****************************************************************************************
'** Copyright Notice
'**
'** Web Wiz Forums(TM)
'** http://www.webwizforums.com
'**
'** Copyright (C)2001-2008 Web Wiz(TM). All Rights Reserved.
'**
'** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS UNDER LICENSE FROM 'WEB WIZ'.
'**
'** IF YOU DO NOT AGREE TO THE LICENSE AGREEMENT THEN 'WEB WIZ' IS UNWILLING TO LICENSE
'** THE SOFTWARE TO YOU, AND YOU SHOULD DESTROY ALL COPIES YOU HOLD OF 'WEB WIZ' SOFTWARE
'** AND DERIVATIVE WORKS IMMEDIATELY.
'**
'** If you have not received a copy of the license with this work then a copy of the latest
'** license contract can be found at:-
'**
'** http://www.webwizguide.com/license
'**
'** For more information about this software and for licensing information please contact
'** 'Web Wiz' at the address and website below:-
'**
'** Web Wiz, Unit 10E, Dawkins Road Industrial Estate, Poole, Dorset, BH15 4JD, England
'** http://www.webwizguide.com
'**
'** Removal or modification of this copyright notice will violate the license contract.
'**
'****************************************************************************************
'*************************** SOFTWARE AND CODE MODIFICATIONS ****************************
'**
'** MODIFICATION OF THE FREE EDITIONS OF THIS SOFTWARE IS A VIOLATION OF THE LICENSE
'** AGREEMENT AND IS STRICTLY PROHIBITED
'**
'** If you wish to modify any part of this software a license must be purchased
'**
'****************************************************************************************
'Set the response buffer to true
Response.Buffer = True
'Dimension variables
Dim strMode 'holds the mode of the page, set to true if changes are to be made to the database
Dim strThreadOrder 'Holds the order the threads are in
Dim blnAvatarImages 'Set to true if avatar images are on
Dim intRepliesPerPage 'Holds the number of replies per page
Dim intHotTopicViews 'Holds the number of views before a topic becomes hot
Dim intHotTopicReplies 'Holds the number of replies before a topic becomes hot
Dim strForumName 'Holds the forum name
Dim blnProcessTime 'Set to true if the user wants the page genration time displayed
Dim blnAuthorEdited 'Set to true if the user wants the name of a post editor displayed
Dim intPollChoice 'Holds the numebr of Poll Choices
'Read in the users details for the forum
strForumName = Request.Form("forumName")
strWebSiteName = Request.Form("siteName")
strWebsiteURL = Request.Form("siteURL")
strForumPath = Request.Form("forumPath")
blnTextLinks = CBool(Request.Form("textLinks"))
blnRTEEditor = CBool(Request.Form("IEEditor"))
intTopicPerPage = CInt(Request.Form("topic"))
blnEmoticons = CBool(Request.Form("emoticons"))
strThreadOrder = Request.Form("threadOrder")
intPollChoice = CInt(Request.Form("pollChoice"))
blnAvatarImages = CBool(Request.Form("avatar"))
intRepliesPerPage = CInt(Request.Form("threads"))
intHotTopicViews = CInt(Request.Form("hotViews"))
intHotTopicReplies = CInt(Request.Form("hotReplies"))
blnActiveUsers = CBool(Request.Form("activeUsers"))
blnProcessTime = CBool(Request.Form("processTime"))
blnAuthorEdited = CBool(Request.Form("edited"))
blnFlashFiles = CBool(Request.Form("flash"))
blnTopicIcon = CBool(Request.Form("TopicIcons"))
blnLongRegForm = CBool(Request.Form("reg"))
blnCAPTCHAsecurityImages = CBool(Request.Form("CAPTCHA"))
blnGuestSessions = CBool(Request.Form("GuestSID"))
blnRSS = CBool(Request.Form("RSS"))
strMode = Request.Form("mode")
blnWebWizNewsPad = CBool(Request.Form("NewsPad"))
strWebWizNewsPadURL = Request.Form("NewsPadURL")
'Initialise the SQL variable with an SQL statement to get the configuration details from the database
strSQL = "SELECT " & strDbTable & "Configuration.* From " & strDbTable & "Configuration WHERE " & strDbTable & "Configuration.ID=1;"
'Set the cursor type property of the record set to Dynamic so we can navigate through the record set
rsCommon.CursorType = 2
'Set the Lock Type for the records so that the record set is only locked when it is updated
rsCommon.LockType = 3
'Query the database
rsCommon.Open strSQL, adoCon
'If the user is changing tthe colours then update the database
If Request.Form("postBack") AND blnDemoMode = False Then
'Update the recordset
With rsCommon
.Fields("forum_name") = strForumName
.Fields("website_path") = strWebsiteURL
.Fields("IE_editor") = blnRTEEditor
.Fields("Text_link") = blnTextLinks
.Fields("Topics_per_page") = intTopicPerPage
.Fields("website_name") = strWebSiteName
.Fields("forum_path") = strForumPath
.Fields("Emoticons") = blnEmoticons
.Fields("Avatar") = blnAvatarImages
.Fields("Threads_per_page") = intRepliesPerPage
.Fields("Hot_views") = intHotTopicViews
.Fields("Hot_replies") = intHotTopicReplies
.Fields("Active_users") = blnActiveUsers
.Fields("Process_time") = blnProcessTime
.Fields("Show_edit") = blnAuthorEdited
.Fields("Flash") = blnFlashFiles
.Fields("Vote_choices") = intPollChoice
.Fields("Topic_icon") = blnTopicIcon
.Fields("Long_reg") = blnLongRegForm
.Fields("CAPTCHA") = blnCAPTCHAsecurityImages
.Fields("Guest_SID") = blnGuestSessions
.Fields("RSS") = blnRSS
.Fields("NewsPad") = blnWebWizNewsPad
.Fields("NewsPad_URL") = strWebWizNewsPadURL
'Update the database with the new user's colours
.Update
'Re-run the query to read in the updated recordset from the database
.Requery
End With
'Update variables
Application.Lock
Application(strAppPrefix & "strMainForumName") = strForumName
Application(strAppPrefix & "strWebsiteURL") = strWebsiteURL
Application(strAppPrefix & "blnTextLinks") = blnTextLinks
Application(strAppPrefix & "blnRTEEditor") = blnRTEEditor
Application(strAppPrefix & "intTopicPerPage") = intTopicPerPage
Application(strAppPrefix & "strWebsiteName") = strWebSiteName
Application(strAppPrefix & "strForumPath") = strForumPath
Application(strAppPrefix & "blnEmoticons") = blnEmoticons
Application(strAppPrefix & "blnAvatar") = blnAvatarImages
Application(strAppPrefix & "intThreadsPerPage") = intRepliesPerPage
Application(strAppPrefix & "intNumHotViews") = intHotTopicViews
Application(strAppPrefix & "intNumHotReplies") = intRepliesPerPage
Application(strAppPrefix & "blnActiveUsers") = blnActiveUsers
Application(strAppPrefix & "blnShowProcessTime") = blnProcessTime
Application(strAppPrefix & "blnShowEditUser") = blnAuthorEdited
Application(strAppPrefix & "blnFlashFiles") = blnFlashFiles
Application(strAppPrefix & "intMaxPollChoices") = intPollChoice
Application(strAppPrefix & "blnTopicIcon") = blnTopicIcon
Application(strAppPrefix & "blnLongRegForm") = blnLongRegForm
Application(strAppPrefix & "blnCAPTCHAsecurityImages") = blnCAPTCHAsecurityImages
Application(strAppPrefix & "blnGuestSessions") = CBool(blnGuestSessions)
Application(strAppPrefix & "blnRSS") = CBool(blnRSS)
Application(strAppPrefix & "blnWebWizNewsPad") = CBool(blnWebWizNewsPad)
Application(strAppPrefix & "strWebWizNewsPadURL") = strWebWizNewsPadURL
'Empty the application level variable so that the changes made are seen in the main forum
Application(strAppPrefix & "blnConfigurationSet") = false
Application.UnLock
End If
'Read in the forum colours from the database
If NOT rsCommon.EOF Then
'Read in the colour info from the database
strForumName = rsCommon.Fields("forum_name")
strWebsiteURL = rsCommon.Fields("website_path")
blnTextLinks = rsCommon.Fields("Text_link")
blnRTEEditor = rsCommon.Fields("IE_editor")
intTopicPerPage = CInt(rsCommon.Fields("Topics_per_page"))
strWebSiteName = rsCommon("website_name")
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -