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

📄 sjedit2.asp

📁 这是ASP的网上考试系统。 希望大家来分享
💻 ASP
字号:
<!-- #include file="cookies.asp" -->
<!-- #include file="conn.asp" -->
<html>
<head>
<title>编辑试卷</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>

<body bgcolor="#FFFFFF" text="#000000">
<div align="center">
        <form name="form1" method="post" action="sjeditsave.asp?id=<%=request.querystring("id")%>&typeid=<%=request.querystring("typeid")%>">
  <table width="90%" border="0" cellspacing="0" cellpadding="0" height="25" bgcolor="#CCCCCC">
    <tr> 
        <td> 
          <div align="center"><b>修改试题</b></div>
        </td>
    </tr>
  </table>
  <%
  set rs1=server.createobject("adodb.recordset")
  sql1="select * from ks where id="&request.querystring("id")
  rs1.open sql1,conn,1,1
  if not rs1.eof then
  %>
    <br><table width="90%" border="0">
      <tr bgcolor="#D8EDFE"> 
        <td height="25" width="100">所属分类:</td>
        <td height="25"> 
          <%
	  set rs=server.createobject("adodb.recordset")
	  sql="select * from kstype"
	  rs.open sql,conn,1,1
	  if not rs.eof then
	  %>
          <select name="kstypeid">
            <%do while not rs.eof%>
            <option <%if rs1("kstypeid")=rs("id") then%>selected<%else%>select<%end if%> value="<%=rs("id")%>"><%=rs("kstype")%></option>
            <%rs.movenext
		  loop
		  end if
		  rs.close
		  set rs=nothing
		  %>
          </select>
        </td>
      </tr>
      <tr bgcolor="#D8EDFE"> 
        <td height="25" width="100">试题:</td>
        <td height="25"> 
          <input type="text" name="title" maxlength="100" size="50" value="<%=trim(rs1("title"))%>">
          (100个字符以内)</td>
      </tr>
      <tr bgcolor="#D8EDFE"> 
        <td height="25" width="100">答案A:</td>
        <td height="25"> 
          <input type="text" name="a" value="<%=trim(rs1("a"))%>">
        </td>
      </tr>
      <tr bgcolor="#D8EDFE"> 
        <td height="25" width="100">B:</td>
        <td height="25"> 
          <input type="text" name="b" value="<%=trim(rs1("b"))%>">
        </td>
      </tr>
      <tr bgcolor="#D8EDFE"> 
        <td height="25" width="100">C:</td>
        <td height="25"> 
          <input type="text" name="c" value="<%=trim(rs1("c"))%>">
        </td>
      </tr>
      <tr bgcolor="#D8EDFE"> 
        <td height="25" width="100">D:</td>
        <td height="25"> 
          <input type="text" name="d" value="<%=trim(rs1("d"))%>">
        </td>
      </tr>
      <tr bgcolor="#D8EDFE"> 
        <td height="25" width="100">正确答案:</td>
        <td height="25"> 
          <select name="da">
            <option value="a" <%if trim(rs1("da"))="a" then%>selected<%else%>select<%end if%>>A</option>
            <option value="b" <%if trim(rs1("da"))="b" then%>selected<%else%>select<%end if%>>B</option>
            <option value="c" <%if trim(rs1("da"))="c" then%>selected<%else%>select<%end if%>>C</option>
            <option value="d" <%if trim(rs1("da"))="d" then%>selected<%else%>select<%end if%>>D</option>
          </select>
        </td>
      </tr>
    </table>
        <%end if
		rs1.close
		set rs1=nothing
		conn.close
		set conn=nothing
		%>  
    <input type="submit" name="Submit" value="修改">
    <input type="reset" name="Submit2" value="重写">
  </form>
  <p>&nbsp;</p>
  <p>&nbsp;</p>
</div>
</body>
</html>

⌨️ 快捷键说明

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