stuUnitTest.jsp
上传用户:nbluoke
上传日期:2013-08-09
资源大小:4851k
文件大小:4k
源码类别:

教育系统应用

开发平台:

WORD

  1. <%@ page contentType="text/html; charset=gb2312" language="java" import="java.sql.*" %>
  2. <%@ page errorPage="QuestGen_error.jsp" %>
  3. <%@ page import="java.io.*"%>
  4. <jsp:useBean id="DBCon" class="jinghua.JinghuaConn" scope="session">
  5. </jsp:useBean>
  6. <jsp:useBean id="Tools" class="jinghua.Tools" scope="session">
  7. </jsp:useBean>
  8. <script language="javascript">
  9. function CheckForm(f)
  10. {
  11. if( !(form.testnum[0].checked || form.testnum[1].checked||form.testnum[2].checked||form.testnum[3].checked) ) {
  12. alert("请选择试题个数 !!")
  13. return false;
  14. }
  15. return true;
  16. }
  17. function isNumberString (InString,RefString)
  18. {
  19. if(InString.length==0) return (false);
  20. for (Count=0; Count < InString.length; Count++)  {
  21. TempChar= InString.substring (Count, Count+1);
  22. if (RefString.indexOf (TempChar, 0)==-1)
  23. return (false);
  24. }
  25. return (true);
  26. }
  27. function msg(str)
  28. {
  29.    alert(str);
  30. }
  31. </script>
  32. <HTML><HEAD><TITLE>在线测试</TITLE>
  33. <META http-equiv=Content-Type content="text/html; charset=gb2312">
  34. <META content="MSHTML 6.00.2462.0" name=GENERATOR></HEAD>
  35. <BODY>
  36. <%!Connection con=null;
  37. String studentID="";
  38. %>
  39. <%
  40.   if(con==null){
  41.     con=DBCon.getConnection();
  42.   }
  43.  %>
  44. <FORM action="UnitTestShow.jsp" method="post" name="form1" id="form1" onSubmit="return CheckForm(this)">
  45.    <A
  46. href="http://jsptestonline.cosoft.org.cn/">首页</A>--共创题库--在线考试 
  47.   <P align="center"> 选择单元测试类型</P>
  48.   <div align="center">
  49.     <table bordercolor=#d3add1 height=243 width="52%" border=1>
  50.       <tbody>
  51.         <tr> 
  52.           <td
  53.     height=41 align="center" valign=middle background=images/lvbgcolor.gif><br> 
  54.             <div align="left"> 
  55.               <table width="100%" border="0">
  56.                 <tr> 
  57.                   <td width="29%" align="right"> &nbsp;&nbsp;&nbsp; </td>
  58.                   <td width="46%" align="left">年 &nbsp;级: 
  59.                     <select id=select6 name=Grade>
  60.                       <%Tools.showOption("select * from grade order by id",con,out);%>
  61.                     </select></td>
  62.                   <td width="25%">&nbsp; </td>
  63.                 </tr>
  64.               </table>
  65.               &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</div></td>
  66.         </tr>
  67.         <tr> 
  68.           <td
  69.     height=63 align="center" valign=middle background=images/lvbgcolor.gif> <div align="left"> 
  70.               <br>
  71.               <table width="100%" border="0">
  72.                 <tr> 
  73.                   <td width="29%" align="right" valign="middle">&nbsp; </td>
  74.                   <td width="54%" align="left" valign="middle">科 &nbsp;目: 
  75.                     <select id=select4 name=Subject>
  76.                       <%Tools.showOption("select * from subject order by id",con,out);%>
  77.                     </select> </td>
  78.                   <td width="17%" valign="middle">&nbsp; </td>
  79.                 </tr>
  80.               </table>
  81.               &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  82.               &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  83.             </div></td>
  84.         </tr>
  85.         <tr> 
  86.           <td
  87.     height=74 align="center" valign=middle background=images/lvbgcolor.gif>
  88. <table width="100%" border="0">
  89.               <tr> 
  90.                 <td width="29%" height="27" align="right"> </td>
  91.                 <td width="46%" align="left">知识点: 
  92.                   <select name=KnowPoint id="select11">
  93.                     <% Tools.showOption("select * from knowpoint order by id",con,out);%>
  94.                   </select></td>
  95.                 <td width="25%">&nbsp; </td>
  96.               </tr>
  97.             </table>
  98.             
  99.           </td>
  100.         </tr>
  101.         <tr>
  102.           <td
  103.     height=31 align="center" valign=middle background=images/lvbgcolor.gif><table width="100%" border="0">
  104.               <tr> 
  105.                 <td width="35%" align="right"> 
  106.                   <input type="submit" name="Submit" value="确定">
  107.                 </td>
  108.                 <td width="24%" align="right">&nbsp;</td>
  109.                 <td width="41%" align="left">
  110. <input name="Reset_Quest" type="reset" id="Reset_Quest4" value="重置">
  111.                 </td>
  112.               </tr>
  113.             </table></td>
  114.         </tr>
  115.       </tbody>
  116.     </table>
  117.   </div>
  118.   <P> </P>
  119. <P>&nbsp;</P>
  120. <P>&nbsp;</P></FORM>
  121. </BODY></HTML>