%
Server.ScriptTimeOut = 300
DB_CONNECTION_STRING = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath("../database/smwq_104quiz1.mdb") & ";"
QUIZ_TAG = "HCMHC"
SAVE_ANSWERS = True
QUESTIONS_TO_SHOW = 7
RANDOM_QUESTIONS = True
RANDOM_ANSWERS = True
PASSWORD = ""
ALLOW_ONE_ACCESS = True
MAX_TIME = -240
NO_BACK_BUTTON = False
NO_USER_CHANGES = False
SEND_ANSWERS_EMAIL_FROM = "isern@plainsfolk.com"
SEND_ANSWERS_EMAIL = ""
SHOW_RIGHT_ANSWERS = True
SHOW_FULL_RESULTS = True
SHOW_TOTAL_SCORE = True
SHOW_EVALUATION = True
SHOW_COMMENT_AFTER_ANSWER = False
MULTI_PAGE = False
TIME_ZONE = 0
'SECURITY_OPTIONS = " ondragstart=""return false"" onselectstart=""return false"" onBeforePrint=""document.body.style.display = 'none';"" onAfterPrint=""document.body.style.display = 'block';"""
SHOW_PRINT_BUTTON = True
SHOW_CLOSE_BUTTON = False
SHOW_IP_ADDRESS = True
SHOW_PRINT_CERTIFICATE_BUTTON = True
SEND_ANSWERS_EMAIL_FORMAT = 0 '0=Questions and all given answers 1=Questions and wrong given answers 2=Questions and all given answers and all correct answers
SET_PAGECODE = False
USE_DEDICATED_PDF_COMPONENT = False
FORCE_UTF_8 = True
If FORCE_UTF_8 Then
Response.CharSet = "utf-8"
Session.CodePage = 65001
Else
Response.CharSet = sLanguageString(53)
Session.CodePage = sLanguageString(54)
End If
Dim sCertificateSource
CreditString = "
" & sLanguageString(0) & " "
'--- Do not edit below this line ---
iDBType = 0
If Instr(DB_CONNECTION_STRING, "Provider=SQLOLEDB.1") > 0 Then iDBType = 1
iTimeOut = Abs(MAX_TIME \ 60) * 2
If iTimeOut < 90 Then iTimeOut = 90
Session.TimeOut = iTimeOut
lUserID = CLng(Request.Form("UserID"))
iStatusID = CLng(Request.Form("StatusID")) '-1=Ready to evaluate, 0=First time, >0=Question number
iDirection = CLng(Request.Form("Direction")) '1=Next, -1=Back
sAnswersSequence = Request.Form("AnswersSequence")
If iStatusID > 1 And iDirection = 1 And MULTI_PAGE And SHOW_COMMENT_AFTER_ANSWER And Request.Form("Comments") <> "" Then
iStatusID = iStatusID - 1
bShowCommentsNow = True
End If
Function IsPrivateQuiz()
OpenConnection True
sSQL = "SELECT COUNT(*) FROM AllowedUsers"
If iDBType = 1 Then sSQL = sSQL & " AND QuizID=" & iQuizID
rsQuiz.Open sSQL, cnnQuiz, 1
IsPrivateQuiz = rsQuiz(0) > 0
CloseConnection rsQuiz, cnnQuiz
End Function
Function GetQuestionCount()
OpenConnection True
sSQL = "SELECT COUNT(*) FROM Questions"
If iDBType = 1 Then sSQL = sSQL & " AND QuizID=" & iQuizID
rsQuiz.Open sSQL, cnnQuiz, 1
GetQuestionCount = rsQuiz(0)
CloseConnection rsQuiz, cnnQuiz
End Function
Function CheckPassword()
If PASSWORD <> "" And UCase(Request.Form("TestPassword")) = UCase(PASSWORD) Then Session("TestPassword") = UCase(PASSWORD)
If PASSWORD <> "" And Session("TestPassword") <> UCase(PASSWORD) Then
PrintHeader ""
Response.Write "