?? testmain.asp
字號:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!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">
<!--
.style1 {
font-family: "華文行楷";
font-size: 36px;
}
body {
background-image: url(images/bk2.gif);
}
.STYLE3 {font-family: "華文行楷"; font-size: 24px; }
-->
</style>
</head>
<body bgcolor="#E8F3FF">
<span class="STYLE3">一.單項選擇題</span>
<hr>
<span class="style1"></span>
<form action="judge.asp" method="post">
<%
Dim conn,sql,rs,counter
conn.open"Driver={Microsoft Access Driver (*.mdb)};DBQ="& server.MapPath("..\data\testlib.mdb")
sql="select * from testselect1new"
set rs=server.CreateObject("ADODB.Recordset")
rs.open sql,conn
response.Write("<table width=100% height=30 border=1 >")
counter=0
Do while(Not rs.eof)
response.Write("<TR bgcolor='yellow'>")
response.Write("<TD width='5%'>"&trim(rs("num"))&"."&"</TD>")
response.Write("<TD width='95%'>"&rs("question")&"</TD>")
response.Write("</TR>")
response.Write("<TR bgcolor='yellow'>")
response.Write("<TD width='5%'>"&"<input name='"&trim(rs("num"))&"' type='radio' value='A' checked='checked'>"&"</TD>")
response.Write("<TD width='95%'>"&rs("option1")&"</TD>")
response.Write("</TR>")
response.Write("<TR bgcolor='yellow'>")
response.Write("<TD width='5%'>"&"<input name='"&trim(rs("num"))&"' type='radio' value='B'>"&"</TD>")
response.Write("<TD width='95%'>"&rs("option2")&"</TD>")
response.Write("</TR>")
response.Write("<TR bgcolor='yellow'>")
response.Write("<TD width='5%'>"&"<input name='"&trim(rs("num"))&"' type='radio' value='C'>"&"</TD>")
response.Write("<TD width='95%'>"&rs("option3")&"</TD>")
response.Write("</TR>")
response.Write("<TR bgcolor='yellow'>")
response.Write("<TD width='5%'>"&"<input name='"&trim(rs("num"))&"' type='radio' value='D'>"&"</TD>")
response.Write("<TD width='95%'>"&rs("option4")&"</TD>")
response.Write("</TR>")
counter=counter+1
rs.MoveNext
Loop
response.Write("</table>")
rs.close
conn.close
set conn=nothing
session("n")=counter
%>
<input type="submit" name="Submit" value="提交">
<input type="reset" name="Submit" value="重選">
</form>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -