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

📄 score_view_list.asp

📁 c++builder开发系统实现了成绩查寻
💻 ASP
字号:
<%@LANGUAGE="JAVASCRIPT"%>
<%
if((Session("rank")!=0&&Session("rank")!=1)||Session("passed")!=12287666342)
{Response.Redirect("index.htm");
 Response.End();
 }
 %>
<!--#include file="Connections/conn1.asp" -->
<%
var Recordset1__userno1 = "0";
if (String(Request("userno")) != "undefined" && 
    String(Request("userno")) != "") { 
  Recordset1__userno1 = String(Request("userno"));
}
%>
<%
var Recordset1__month1 = "s2";
if (String(Request("month")) != "undefined" && 
    String(Request("month")) != "") { 
  Recordset1__month1 = String(Request("month"));
}
%>
<%
var Recordset1__classid1 = "0";
if (String(Session("ranage")) != "undefined" && 
    String(Session("ranage")) != "") { 
  Recordset1__classid1 = String(Session("ranage"));
}
%>
<%
 if(Session("ranage")>0)
 {var Recordset1 = Server.CreateObject("ADODB.Recordset");
Recordset1.ActiveConnection = MM_conn1_STRING;
Recordset1.Source = "SELECT username,"+ Recordset1__month1.replace(/'/g, "''") + "  FROM user,score  WHERE user.userno=score.userno AND user.userno='"+ Recordset1__userno1.replace(/'/g, "''") + "' AND user.classid="+ Recordset1__classid1.replace(/'/g, "''") + "";
Recordset1.CursorType = 0;
Recordset1.CursorLocation = 2;
Recordset1.LockType = 1;
Recordset1.Open();
}
if(Session("ranage")<0)
 {var Recordset1 = Server.CreateObject("ADODB.Recordset");
Recordset1.ActiveConnection = MM_conn1_STRING;
Recordset1.Source = "SELECT username,"+ Recordset1__month1.replace(/'/g, "''") + "  FROM user,score  WHERE user.userno=score.userno AND user.userno='"+ Recordset1__userno1.replace(/'/g, "''") + "' ";
Recordset1.CursorType = 0;
Recordset1.CursorLocation = 2;
Recordset1.LockType = 1;
Recordset1.Open();
}
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>福州大学数学与计算机科学学院综合测评分管理系统</title>
<style type="text/css">
<!--
body {
	background-image: url(imag/bjx.jpg);
}
.style18 {
	font-style: italic;
	font-size: 14px;
	color: #FFFF66;
}
.style19 {color: #666666}
.style31 {font-size: 12px}
.style32 {color: #FFFFFF}
.style42 {color: #FF0000; font-size: 12px; }
.style44 {color: #FFFFFF; font-style: italic; }
.style49 {
	color: #FF0000;
	font-style: italic;
	font-size: 14px;
}
.style51 {color: #FF6600; font-size: 12px; }
.style54 {color: #000000; font-size: 12px; }
.style55 {color: #000000}
-->
</style></head>

<body>
<table width="700" height="529" border="0" align="center" cellpadding="0" cellspacing="0">
  <!--DWLayoutTable-->
  <tr>
    <td width="89" height="13"></td>
    <td width="713"><div align="center"><img src="imag/Top_logo.jpg" width="596" height="110"></div></td>
    <td width="48"></td>
  </tr>
  <tr>
    <td height="406"></td>
    <td valign="top"><table width="570" border="0" cellpadding="0" cellspacing="0">
        <!--DWLayoutTable-->
        <tr>
          <td width="850" height="395"><table width="700" border="0" align="center" cellpadding="0" cellspacing="0">
              <tr>
                <th width="37" scope="col">&nbsp;</th>
                <th width="626" height="358" scope="col"><table width="600" height="52" border="1" align="center" cellpadding="0" cellspacing="0">
                  <% if (!Recordset1.EOF || !Recordset1.BOF) { %>
                  <tr bordercolor="#6699CC" bgcolor="#CCCCCC">
                    <th height="13" colspan="8" scope="col"></th>
                    </tr>
                  <tr bgcolor="#999999">
                    <th width="51" height="13" scope="col"><div align="center" class="style31">
                      <div align="center"><em><span class="style32">姓名</span></em></div>
                    </div></th>
                    <th width="147" scope="col"><div align="center"><span class="style54"><%=(Recordset1.Fields.Item("username").Value)%></span></div></th>
                    <th width="40" scope="col"><div align="center" class="style31">
                      <div align="center"><span class="style44">学号</span></div>
                    </div></th>
                    <th width="112" scope="col"><div align="center" class="style51">
                      <div align="center" class="style55"><%=Request("userno")%></div>
                    </div></th>
                    <th width="39" scope="col"><div align="center" class="style31">
                      <div align="center"><span class="style44">月份</span></div>
                    </div></th>
                    <th width="75" scope="col"><div align="center" class="style42 style55">
					      <div align="center">
					        <% var a=Request("month")(1); if(a!="total1"&&a!="total2") 
					  Response.Write(a.charAt(1)+"月"); if(a=='total1') Response.Write("上半年总评"); if(a=='total2') Response.Write("下半年总评");%>
					    
					      </div>
                    </div></th>
                    <th width="39" scope="col"><div align="center" class="style54">
                      <div align="center" class="style32"><em>成绩</em></div>
                    </div></th>
                    <th width="97" scope="col"><div align="center" class="style42 style55">
                          <div align="center">
                            <%var x=Recordset1.Fields.Item(Recordset1__month1).Value; if(x==null) Response.Write("暂无该月成绩");else Response.Write(x);%>
                          </div>
                    </div></th>
                  </tr>
                  <tr bordercolor="#6699CC" bgcolor="#CCCCCC">
                    <th height="13" colspan="8" scope="col"></th>
                    </tr>
                  <% } // end !Recordset1.EOF || !Recordset1.BOF %>

                  <tr bgcolor="#CCCCCC">
                    <% if (Recordset1.EOF && Recordset1.BOF) { %>
                    <th height="13" colspan="8" scope="col"><span class="style49">对不起!您不能查看该成绩。可能原因是:无此人或该人不属于你们班</span></th>
                    <% } // end Recordset1.EOF && Recordset1.BOF %>
</tr>
                </table></th>
                <th width="37" scope="col">&nbsp;</th>
              </tr>
            </table>
            <table width="570" height="48" border="0" align="center" cellpadding="0" cellspacing="0">
              <tr>
                <th height="48" scope="col">&nbsp;</th>
              </tr>
            </table></td>
        </tr>
    </table></td>
    <td></td>
  </tr>
  <tr>
    <td height="13"></td>
    <td ><div align="center" class="style18">
      <p class="style19 style31">&nbsp;</p>
    </div></td>
    <td></td>
  </tr>
</table>
</body>
</html>
<%
Recordset1.Close();
%>

⌨️ 快捷键说明

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