⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pg_yued.asp

📁 是一个电子商务网站的功能介绍
💻 ASP
字号:
<!--#include file="conn.asp"-->
 <%
  if session("adminname")="" then
  response.redirect "relogin.asp"
  end if

%>
 <%
userid=request("userid")
  sql1="SELECT * from tbuser where userid="&userid
set rs1=server.createobject("adodb.recordset")
rs1.open sql1,conn,3,2

username=rs1("username")
kcid=request("kcid")
paperno=request("paperno")
nianji=rs1("nianji")
banji=rs1("banji")
category=request("category")




 %>

<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><center><b><%=nianji%>级--<%=banji%>——<%=username%></b></center>

<% sqltm="SELECT  *  FROM tbkcconfig  where kcid="&kcid&" and category=8 and paperno="&paperno

set rstm=server.createobject("adodb.recordset")
rstm.open sqltm,conn,3,2  


 sqlp="SELECT  *  FROM tbpaper where paperno="&paperno
set rsp=server.createobject("adodb.recordset")
rsp.open sqlp,conn,3,2  


  sql_fen="SELECT   top "&rstm("datano")&" userdata.fen,userdata.tmid,userdata.dataid  FROM  userdata,tbtk  where username='"&username&"' and userdata.tmid=tbtk.tmid   and tbtk.kcid="&kcid&"  and paperno="&paperno&"  and category=8 and kao=1 order by tbtk.tmid"
   set rs_fen=server.createobject("adodb.recordset")
   rs_fen.open sql_fen,conn,3,2

  xiaotino=0
   yued_fen=0
  do while not rs_fen.eof
  
   sql_fen1="SELECT   *  FROM  userdataread  where username='"&username&"'  and dataid="&rs_fen("dataid")&"  and tmid="&rs_fen("tmid")&"   and paperno="&paperno&"  "
   set rs_fen1=server.createobject("adodb.recordset")
   rs_fen1.open sql_fen1,conn,3,2
  
   xiaotino=rs_fen1.recordcount+xiaotino
      do while not rs_fen1.eof
        yued_fen=rs_fen1("fen")+yued_fen
 
        rs_fen1.movenext
      loop
      
   rs_fen.movenext
  loop
    

  sql="SELECT  top  "&rstm("datano")&"  tbtk.tmid, tbtk.title,tbtk.category, tbkc.kcid, tbkc.kcm, tbtk.chapter,a,b,c,d,e,f,photo  FROM tbkc, userdata, tbtk  WHERE username='"&username&"' and userdata.tmid=tbtk.tmid and tbtk.kcid=tbkc.kcid and tbkc.kcid="&kcid&"  and paperno="&paperno &" and kao=1  and category=8 order by tbtk.tmid;"

set rs=server.createobject("adodb.recordset")
rs.open sql,conn,3,2
on error resume next

%>当前位置:批改试卷 &gt; <%=rs("kcm")%>——<%=rsp("info")%>


 
<center><form name="viewdatabase"  ACTION="<%=Myself%>"  method="post">
  <table border="1" cellspacing="1" style="border-collapse: collapse" bordercolor="#799AE1" width="100%" id="AutoNumber1" height="392">
    <tr class="trh">
      <td width="59" align="center" bgcolor="#799AE1" height="26">
      <font color="#FFFFFF"><b>序号</b></font></td>
      <td align="center" bgcolor="#799AE1" width="691" height="26">
      <p align="center"><font color="#FFFFFF"><b>阅读理解(共<%=rstm("datano")&"大题--"&xiaotino&"小题"%>,<%=rstm("datavalue")*xiaotino&"分"%>)</b></font></td>
    </tr>
    <%  



rs.PageSize =1

Page = CLng(Request("Page"))

If Page < 1 Then Page = 1
If Page > rs.PageCount Then Page = rs.PageCount
i=page+(page-1)*0
rs.AbsolutePage = Page
For iPage = 1 To rs.PageSize

 


 

%>
    
    <tr>
      <td align="center" bgcolor="#FFFDE8" height="68" width="59" bordercolor="#215DC6"><%=i%> </td>
      <td align="center" bgcolor="#FFFDE8" height="68" width="691" bordercolor="#215DC6">
      <table border="0" cellpadding="0" width="89%">
		<tr>
			<td><br>试题——<%=htmlencode(rs("title"))%><br>
      <% if len(rs("photo")) > 1 then
            %> <center>
      <img border="0" src="examimage/<%=rs("photo")%>"></center> 
       <br><% end if %><hr color="#000000">
 </td>
		</tr>
		<% 
sqlyued1="SELECT *  FROM tbread  WHERE   tmid="&rs("tmid")&""
set rsyued1=server.createobject("adodb.recordset")
rsyued1.open sqlyued1,conn,3,2
 


do while not rsyued1.eof


sqlyued3="SELECT *  FROM userdataread  WHERE username='"&username&"'  and paperno="&paperno&" and noid="&rsyued1("noid")&" and tmid="&rsyued1("tmid")
set rsyued3=server.createobject("adodb.recordset")
rsyued3.open sqlyued3,conn,3,2
%>
		<tr>
			<td>(<%=rsyued1("readno")%>)、<%=htmlencode(rsyued1("xiaoti"))%>——(难度:<%
			  if  rsyued1("slevel")=1  then 
    response.write "容易"
    end if 
     if  rsyued1("slevel")=2 then 
    response.write "中等"
    end if 
      
      if  rsyued1("slevel")=3 then 
    response.write "较难"
    end if  
       if  rsyued1("slevel")=4  then 
    response.write "最难"
    end if 
      %>) <br><% if len(rsyued1("pic")) > 1 then
            %> <center>
    
      <img border="0" src="examimage/<%=rsyued1("pic")%>"> 
      </center> 
     
       <br><% end if %>
       <% if rsyued1("a")<>"" then %>&nbsp;  &nbsp; &nbsp; A.<%=rsyued1("a")%><br><%end if%>
      
        <% if rsyued1("b")<>"" then %> &nbsp;  &nbsp; &nbsp; B.<%=rsyued1("b")%><br><%end if%>
        <% if rsyued1("c")<>"" then %>&nbsp;  &nbsp;  &nbsp; C.<%=rsyued1("c")%><br><%end if%>

        <% if rsyued1("d")<>"" then %> &nbsp;  &nbsp; &nbsp; D.<%=rsyued1("d")%><br><%end if%>

        <% if rsyued1("e")<>"" then %> &nbsp;  &nbsp;  &nbsp; E.<%=rsyued1("e")%><br><%end if%>
        <% if rsyued1("f")<>"" then %> &nbsp;  &nbsp;  &nbsp; F.<%=rsyued1("f")%><br><%end if%>
      标准答案: <b><% if trim(rsyued3("rans"))="A" then %>A.<%=rsyued1("a")%><%end if%>
     <% if trim(rsyued3("rans"))="B" then %>B.<%=rsyued1("b")%><%end if%>
<% if trim(rsyued3("rans"))="C" then %>C.<%=rsyued1("c")%><%end if%>
<% if trim(rsyued3("rans"))="D" then %>D.<%=rsyued1("d")%><%end if%>
<% if trim(rsyued3("rans"))="E" then %>E.<%=rsyued1("e")%><%end if%>
<% if trim(rsyued3("rans"))="F" then %>F.<%=rsyued1("f")%><%end if%></b><br>

      您的答案:<% 
      '--------------------------------
      if trim(rsyued3("ruans"))="A" then %>
      
          <% if trim(rsyued3("ruans"))<>trim(rsyued3("rans")) then 
     response.write "<font color=red>"%>
     A.<%=rsyued1("a")%>
       <%  response.write "</font>"
       else
       %>
         A.<%=rsyued1("a")%>
       
       <%end if%>
       
      <%end if%>
      
    <% '--------------------------------
    if trim(rsyued3("ruans"))="B" then %>
     <% if trim(rsyued3("ruans"))<>trim(rsyued3("rans")) then 
     response.write "<font color=red>"%>
     B.<%=rsyued1("b")%>
       <%  response.write "</font>"
       else
       %>
         B.<%=rsyued1("b")%>
       
       <%end if%>
       <%end if%>
       
       
       
<%'------------------------------------
 if trim(rsyued3("ruans"))="C" then %>
          <% if trim(rsyued3("ruans"))<>trim(rsyued3("rans")) then 
     response.write "<font color=red>"%>
     C.<%=rsyued1("c")%>
       <%  response.write "</font>"
       else
       %>
         C.<%=rsyued1("c")%>
       <%end if%>
 <%end if%>
 
 
<% '-------------------------------------
if trim(rsyued3("ruans"))="D" then %>        
  <% if trim(rsyued3("ruans"))<>trim(rsyued3("rans")) then 
     response.write "<font color=red>"%>
     D.<%=rsyued1("d")%>
       <%  response.write "</font>"
       else
       %>
         D.<%=rsyued1("d")%>
       
       <%end if%><%end if%>
       
       
       
       
<% '---------------------------------------
if trim(rsyued3("ruans"))="E" then %>
          <% if trim(rsyued3("ruans"))<>trim(rsyued3("rans")) then 
     response.write "<font color=red>"%>
     E.<%=rsyued1("e")%>
       <%  response.write "</font>"
       else
       %>
         E.<%=rsyued1("e")%>
       
       <%end if%><%end if%>
       
<% '-----------------------------------
if trim(rsyued3("ruans"))="F" then %>
          <% if trim(rsyued3("ruans"))<>trim(rsyued3("rans")) then 
     response.write "<font color=red>"%>
     F.<%=rsyued1("f")%>
       <%  response.write "</font>"
       else
       %>
         F.<%=rsyued1("f")%>
       
       <%end if%><%end if%>
       
      <br>
      
      您的得分:
      
      <%
      response.write rsyued3("fen")&"分"
   %><br><hr color="#4455AA"> </td>
		</tr>
		<% rsyued1.movenext
   loop
   %></table>
		</td>
      </tr>
      
      <% 
rs.MoveNext
If rs.EOF Then Exit For
i=i+1
Next
%>
    <tr>
      <td align="center" bgcolor="#FFFFFF" height="38" width="59" bordercolor="#FFFFFF">
         </td>
      <td align="center" bgcolor="#FFFFFF" height="38" width="691" bordercolor="#FFFFFF">
        <input type="button" value="关闭窗口" name="B2" onclick="self.close()" class="s02"></td>
      </tr>
    <caption></caption>
  </table>
</form>
 </center>
 <center> <form ACTION="<%=Myself%>" METHOD="GET">
    <table style="border-collapse: collapse" bordercolor="#111111" cellpadding="0" cellspacing="0">
      <tr>
        <td width="576">
        <p ALIGN="center"><%If Page <> 1 Then ' 如果不是位于第一页%>
        <a href="<%=Myself%>?Page=1&kcid=<%=kcid%>&userid=<%=userid%>&category=<%=category%>&paperno=<%=paperno%>">第一页</a>
        <a HREF="<%=Myself%>?Page=<%=(Page-1)%>&kcid=<%=kcid%>&userid=<%=userid%>&category=<%=category%>&paperno=<%=paperno%>">上一页</a>
        <%                                      
End If                                         
If Page <> rs.PageCount Then ' 如果不是位于最后一页                                         
%> <a HREF="<%=Myself%>?Page=<%=(Page+1)%>&kcid=<%=kcid%>&userid=<%=userid%>&category=<%=category%>&paperno=<%=paperno%>">下一页</a>
        <a HREF="<%=Myself%>?Page=<%=rs.PageCount%>&kcid=<%=kcid%>&userid=<%=userid%>&category=<%=category%>&paperno=<%=paperno%>">最后一页</a>
        <% End If %>&nbsp;
        <font SIZE="2">页次:</font><font COLOR="Red" SIZE="2"><%=Page%>/<%=rs.PageCount%></font></p>
        <p> </td>
      </tr>
    </table>
  </form>
 </center>
<%


%>
</body>

</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -