% @ Language=VBScript %> <% Option Explicit %> <% '**************************************************************************************** '** Copyright Notice '** '** EzASPSite™ '** '** Copyright 2003-2004 VSBrown All Rights Reserved. '** '** This program is free software; you can modify (at your own risk) any part of it '** and use it both privately and commercially. '** '** All copyright notices must remain in tacked in the scripts and the '** outputted HTML. '** '** You may use parts of this program in your own private work, but you may NOT '** redistribute, repackage, or sell the whole or any part of this program even '** if it is modified or reverse engineered in whole or in part without express '** permission from the author. '** '** You may not pass the whole or any part of this application off as your own work. '** '** All links to EzASPSite™ and Powered By EzASPSite™ link must remain unchanged and in place '** and must remain visible when the pages are viewed unless permission is first granted '** by the copyright holder. '** '** This program is distributed in the hope that it will be useful, '** but WITHOUT ANY WARRANTY; without even the implied warranty of '** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR ANY OTHER '** WARRANTIES WHETHER EXPRESSED OR IMPLIED. '** '** No official support is available for EzASPSite™ but you may post support questions at: '** http://www.ezaspsite.com/forum '** '**************************************************************************************** 'Set the response buffer to true Response.Buffer = True 'Make sure this page is not cached Response.Expires = -1 Response.ExpiresAbsolute = Now() - 2 Response.AddHeader "pragma","no-cache" Response.AddHeader "cache-control","private" Response.CacheControl = "No-Store" Dim blnLCode1 'Variables Dim strMode 'This Is The Page Mode Dim sitepath 'This Is The Path To Your Site Dim htmleditor 'This Is The HTML Editor On/Off Feature Dim page3 'This Is Page 3 Contents 'Pull Data From Database '--------------------- Path And Name Of Database -------------------------------------------------------------------------------- strCon = "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath(strEzDBPath3) ' "../../db/ez.mdb" 'Alternative Drivers Faster Than The Default One Above 'strCon = "Provider=Microsoft.Jet.OLEDB.3.51; Data Source=" & Server.MapPath("../db/ez.mdb") 'This one is if you convert the database to Access 97 'strCon = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.MapPath("../db/ez.mdb") 'This one is for Access 2000/2002 'If you wish to use DSN then comment out the driver above and uncomment the line below (DSN is slower than the above drivers) 'strCon = "DSN = DSN_NAME" 'Place the DSN where you see DSN_NAME 'NOTE: For extra security it is highly recommended you change the name of the database, db/ez.mdb, to another name and then 'replace the db/ez.mdb found above with the name you changed the EzASPSite database to. '--------------------------------------------------------------------------------------------------------------------------------------------- 'Read In The Site Details page3 = Request.Form("page3") strMode = Request.Form("mode") Set rsCommon = Server.CreateObject("ADODB.Recordset") strSQL = "SELECT tblSettings.* From tblsettings;" '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, strCon 'If Changing Site Settings Then Update Database If strMode = "change" Then 'Update the recordset With rsCommon .Fields("page3") = page3 'Update the database with the new site settings .Update 'Re-run the query to read in the updated recordset from the database .Requery End With End If 'Read In The Site Settings From Database If NOT rsCommon.EOF Then page3 = rsCommon("page3") htmleditor = rsCommon("htmleditor") sitepath = rsCommon("sitepath") End If 'Reset Server Objects rsCommon.Close Set rsCommon = Server.CreateObject("ADODB.Recordset") strSQL = "SELECT tblHitCount.* From tblHitCount;" rsCommon.Open strSQL, strCon If Not rsCommon.EOF Then blnLCode1 = CBool(rsCommon("L_Code")) End If rsCommon.close %>
Page 3 Contents
Return To Home Page