testinfo.asp
来自「网络考试系统最终备份」· ASP 代码 · 共 201 行
ASP
201 行
<!--#include file="conn.inc"-->
<html>
<head>
<meta http-equiv="Content-Language" content="zh-cn">
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>试卷信息</title>
<link rel="stylesheet" type="text/css" href="css.css">
</head>
<body bgcolor="#EFEFEF">
<%
sql="select * from paper_info where PaperID="&request("testid")
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,3,2
if rs.eof then
response.write "没有参加考试"
else
%>
<table border="1" cellspacing="1" style="border-collapse: collapse" bordercolor="#C0C0C0" width="240" id="AutoNumber1">
<tr>
<td nowrap colspan="5" bgcolor="#E1E1E1" align="center">试卷信息<b><font color="#003399">
</font></b></td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center" width="65">考试编号</td>
<td nowrap align="center" colspan="4"><%=rs("PaperID")%> </td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">科 目</td>
<td nowrap align="center" colspan="4">
<%
v_SubID = rs("Sub_ID")
subsql = "select * from subject_info where SubID = "&v_SubID
set subrs = server.CreateObject("adodb.recordset")
subrs.open subsql,conn,3,2
if not subrs.eof then
v_SubName = subrs("SubName")
else
v_SubName = "科目已被删除"
end if
subrs.close
set subrs = nothing
response.Write(v_SubName)
%>
</td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">卷面总分</td>
<td nowrap align="center" colspan="4"><%=rs("TotalPer")%> </td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center" width="65">单 选 题</td>
<td nowrap align="center" bgcolor="#E1E1E1">数目</td>
<td nowrap align="center"><%=rs("SingleCount")%> </td>
<td nowrap align="center" bgcolor="#E1E1E1" width="30">分值</td>
<td nowrap align="center"><%=rs("SinglePer")%> </td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center" width="65">多 选 题</td>
<td nowrap align="center" bgcolor="#E1E1E1">数目</td>
<td nowrap align="center"><%=rs("MultiCount")%> </td>
<td nowrap align="center" bgcolor="#E1E1E1" width="30">分值</td>
<td nowrap align="center"><%=rs("MultiPer")%> </td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center" width="65">判 断 题</td>
<td nowrap align="center" bgcolor="#E1E1E1">数目</td>
<td nowrap align="center"><%=rs("JudgeCount")%> </td>
<td nowrap align="center" bgcolor="#E1E1E1" width="30">分值</td>
<td nowrap align="center"><%=rs("JudgePer")%> </td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">知 识 点</td>
<td nowrap align="center" colspan="4">
<%
know = rs("PKnow_ID")
'response.write(know)
know=split(know,",")
n=ubound(know)
for i=0 to n
v_know = trim(know(i))
'response.Write(v_know&",")
sql1 = "select * from knowledge_info where KnowID = "&v_know
set rs1 = server.CreateObject("adodb.recordset")
rs1.open sql1,conn,3,2
if not rs1.eof then
response.Write(rs1("KnowName")&"<br>")
end if
rs1.close
set rs1 = nothing
next
%>
</td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">难度系数</td>
<td nowrap align="center" colspan="4"><%=rs("TestDiffRate")%></td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">评分标准</td>
<td nowrap align="center" colspan="4">
<%
sql1= "select * from score_tand where Paper_ID = "&request("testid")
set rs1 = server.CreateObject("adodb.recordset")
rs1.open sql1,conn,3,2
if not rs1.eof then
response.Write("卷面成绩比例:"&rs1("PaperScoreRate"))
response.Write("平时成绩比例:"&rs1("UsualScoreRate"))
else
response.Write("未设置评分标准")
end if
rs1.close
set rs1 = nothing
%> </td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">考试时间</td>
<td nowrap align="center" colspan="4"><%=formatdatetime(rs("StartTime"),2)%> <%=formatdatetime(rs("StartTime"),3)%>—<%=formatdatetime(rs("EndTime"),2)%> <%=formatdatetime(rs("EndTime"),3)%> </td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">有 效 期</td>
<td nowrap align="center" colspan="4"><%=rs("StartTime") -2%>—<%=rs("EndTime")+2%></td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">设 定 人</td>
<td nowrap align="center" colspan="4"><%
sql1="select * from user_info where UserID=" &rs("Set_User_ID")
set rs1=server.createobject("adodb.recordset")
rs1.open sql1,conn,3,2
if not rs1.eof then
response.Write(rs1("UserRName"))
end if
rs1.close
set rs1 = nothing
%> </td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">设定时间</td>
<td nowrap align="center" colspan="4"><%=rs("SetTime")%> </td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">批 准 人</td>
<td nowrap align="center" colspan="4"> <%
puserid = rs("Pass_User_ID")
if puserid <>"" THEN
sql1="select * from user_info where UserID=" &rs("Pass_User_ID")
set rs1=server.createobject("adodb.recordset")
rs1.open sql1,conn,3,2
if not rs1.eof then
response.Write(rs1("UserRName"))
end if
rs1.close
set rs1 = nothing
ELSE
response.Write("未经设置")
END IF
%>
</td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">监 考 人</td>
<td nowrap align="center" colspan="4"><%
sql1="select * from user_info where UserID=" &rs("Monitor_User_ID")
set rs1=server.createobject("adodb.recordset")
rs1.open sql1,conn,3,2
if not rs1.eof then
response.Write(rs1("UserRName"))
end if
rs1.close
set rs1 = nothing
%></td>
</tr>
<tr>
<td nowrap bgcolor="#E1E1E1" align="center">批准时间</td>
<td nowrap align="center" colspan="4"><%if puserid <>"" THEN response.Write(rs("PassTime")) end if %>
</td>
</tr>
</table>
<p align="center">
<input type="button" onClick="self.close();" value="关闭窗口" name="B3" class="s02"></p>
<%
end if
conn.close
set conn = nothing
%>
</body>
</html>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?