?? createtest.aspx
字號(hào):
?<%@ Page Language="C#" AutoEventWireup="true" CodeFile="createTest.aspx.cs" Inherits="createTest" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head >
<title>開始考試</title>
<link href="css/child.css" rel="stylesheet" type="text/css" />
<script type ="text/javascript" >
var time="3600";
var atime="300";
var etime="0";
function count(){
setTimeout("count()",1000);
document.getElementById("timer").value=format(Math.floor(time/60))+"分:"+format(time%60)+"秒";
time--;
if(time==atime){
alert("還剩5分鐘");
}
if(time==etime-1){
clearTimeout(setTimeout("count()",1000));
alert("時(shí)間到,已經(jīng)自動(dòng)提交");
document.form1.submit();
}
}
function format(time){
var len=time.toString().length;
for(i="0";i<2-len;i++){
time="0"+time;
}
return time;
}
function windowopen(){
var open=window.open('about:blank', '', 'height=768, width=1000, top=0, left=0, toolbar=yes, menubar=yes, scrollbars=yes, resizable=yes,location=yes, status=yes');
open.location="result.aspx";
}
</script>
</head>
<body onload="count();">
<a name="top" id="wen"></a>
<form id="Form1" method="post" runat="server" action ="result.aspx">
<table width="1000" border="0" >
<tr>
<td width="1000" colspan="2" style="height: 146px"><img style="width:1000px; height: 146px;" src="image/banner.jpg" /></td>
</tr>
<tr>
<td align="center" height="300">
<table width="1000" align="center" border="1" cellpadding="0" cellspacing="0">
<tr>
<td align="center" colSpan="2"><FONT face="宋體" size="30">《<asp:label id="lbl_courseName" runat="server" ForeColor="Black" Font-Bold="True" Height="30px"></asp:label>》考試試題</FONT></td>
</tr>
<tr>
<td colSpan="2"><FONT face="宋體" color="#ff0033"><span style="font-size: 14pt">考試過程中請(qǐng)不要刷新!否則選擇結(jié)果會(huì)清空!考試時(shí)間為一個(gè)小時(shí)</span></FONT></td>
</tr>
<tr >
<td style="HEIGHT: 25px"><FONT face="宋體"><span style="font-size: 12pt">考試題包括單選、多選、填空、判斷、問答</span></FONT></td>
<td style="HEIGHT: 25px"></td>
</tr>
<tr align="center">
<td colSpan="2" height="600" valign="top">
<table style="width: 579px; height: 1px" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 100px; height: 35px;">
<span style="font-size: 12pt; font-family: 宋體">考生學(xué)號(hào):</span></td>
<td style="width: 100px; height: 35px;">
<asp:label id="lbl_stuId" runat="server" ForeColor="Red" Font-Size="13pt"></asp:label></td>
<td style="width: 100px; height: 35px;">
<span style="font-family: 宋體"><span style="font-size: 12pt"><span>考生姓名:</span> </span>
</span>
</td>
<td style="width: 100px; height: 35px;">
<asp:label id="lbl_stuName" runat="server" ForeColor="Red" Font-Size="13pt"></asp:label></td>
<td style="width: 100px; height: 35px;">
<asp:Button ID="Button1" runat="server" Font-Size="13pt" OnClick="Button1_Click"
Text="交卷" Height="25px" Width="64px" /></td>
</tr>
<tr>
<td colspan="6" style="height: 431px" >
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
Width="685px" Font-Size="12pt" HorizontalAlign="Left">
<Columns>
<asp:TemplateField>
<ItemTemplate>
<table style="width: 545px;">
<tr>
<td colspan="3" style="width: 265px">
<asp:Label ID="Label2" runat="server" Text="<%# Container.DataItemIndex+1 %>" Font-Size="12pt"></asp:Label>
<asp:Label ID="Label3" runat="server" Text='<%# Eval("testContent","、{0}") %>' Font-Size="12pt"></asp:Label>
<asp:Label ID="Label4" runat="server" Text='<%# Eval("rightAns") %>' Visible="False" Font-Size="12pt"></asp:Label>
<asp:Label ID="Label31" runat="server" Text='<%# Eval("testScore") %>' Visible="False" Font-Size="12pt"></asp:Label></td>
</tr>
<tr>
<td colspan="1" style="width: 332px; text-align: left">
<asp:RadioButton ID="RadioButton1" runat="server" GroupName="S1" Text='A:' Font-Size="12pt" />
<asp:Label ID="Label6" runat="server" Text='<%# Eval("testAns1") %>' Font-Size="12pt"></asp:Label></td>
<td colspan="3" style="text-align: left; width: 265px;">
<asp:RadioButton ID="RadioButton2" runat="server" GroupName="S1" Text='B:' Font-Size="12pt" />
<asp:Label ID="Label7" runat="server" Text='<%# Eval("testAns2") %>' Font-Size="12pt"></asp:Label></td>
</tr>
<tr>
<td colspan="1" style="text-align: left; width: 332px;">
<asp:RadioButton ID="RadioButton3" runat="server" GroupName="S1" Text='C:' Font-Size="12pt" />
<asp:Label ID="Label8" runat="server" Text='<%# Eval("testAns3") %>' Font-Size="12pt"></asp:Label></td>
<td colspan="3" style="text-align: left; width: 265px;">
<asp:RadioButton ID="RadioButton4" runat="server" GroupName="S1" Text='D:' Font-Size="12pt" />
<asp:Label ID="Label9" runat="server" Text='<%# Eval("testAns4") %>' Font-Size="12pt"></asp:Label></td>
</tr>
</table>
</ItemTemplate>
<HeaderTemplate>
<asp:Label ID="Label36" runat="server" Text="一、單選題(每題" Font-Size="13pt"></asp:Label>
<asp:Label ID="Label5" runat="server" Text='<%# Eval("testScore") %>' Font-Size="13pt"></asp:Label>
<asp:Label ID="Label37" runat="server" Text="分)" Font-Size="13pt"></asp:Label>
</HeaderTemplate>
<ItemStyle HorizontalAlign="Left" />
</asp:TemplateField>
</Columns>
<EmptyDataRowStyle HorizontalAlign="Left" />
<RowStyle HorizontalAlign="Left" />
<HeaderStyle HorizontalAlign="Left" />
</asp:GridView>
</td>
</tr>
<tr>
<td colspan="6" style="height: 431px">
<asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False"
Width="687px">
<Columns>
<asp:TemplateField>
<ItemTemplate>
<table style="width: 545px">
<tr>
<td colspan="3" style="width: 304px">
<asp:Label ID="Label14" runat="server" Font-Size="13pt" Text="<%# Container.DataItemIndex+1 %>"></asp:Label>
<asp:Label ID="Label15" runat="server" Font-Size="13pt" Text='<%# Eval("testContent","、{0}") %>'></asp:Label>
<asp:Label ID="Label16" runat="server" Font-Size="13pt" Text='<%# Eval("rightAns") %>'
Visible="False"></asp:Label>
<asp:Label ID="Label32" runat="server" Font-Size="13pt" Text='<%# Eval("testScore") %>'
Visible="False"></asp:Label></td>
</tr>
<tr>
<td colspan="1" style="width: 266px;">
<asp:CheckBox ID="CheckBox1" runat="server" Font-Size="13pt" Text="A:" />
<asp:Label ID="Label17" runat="server" Font-Size="13pt" Text='<%# Eval("testAns1") %>'></asp:Label></td>
<td colspan="3" style="width: 310px;">
<asp:CheckBox ID="CheckBox3" runat="server" Font-Size="13pt" Text="B:" />
<asp:Label ID="Label18" runat="server" Font-Size="13pt" Text='<%# Eval("testAns2") %>'></asp:Label></td>
</tr>
<tr>
<td colspan="1" style="width: 266px">
<asp:CheckBox ID="CheckBox2" runat="server" Font-Size="13pt" Text="C:" />
<asp:Label ID="Label19" runat="server" Font-Size="13pt" Text='<%# Eval("testAns3") %>'></asp:Label></td>
<td colspan="4">
<asp:CheckBox ID="CheckBox4" runat="server" Font-Size="13pt" Text="D:" />
<asp:Label ID="Label20" runat="server" Font-Size="13pt" Text='<%# Eval("testAns4") %>'></asp:Label></td>
</tr>
</table>
</ItemTemplate>
<HeaderTemplate>
<asp:Label ID="Label37" runat="server" Font-Size="13pt" Text=" 二、多選題(每題"></asp:Label>
<asp:Label ID="Label10" runat="server" Font-Size="13pt" Text='<%# Eval("testScore") %>'></asp:Label><span
style="font-size: 13pt">分) </span>
</HeaderTemplate>
</asp:TemplateField>
</Columns>
<RowStyle HorizontalAlign="Left" />
<EditRowStyle HorizontalAlign="Left" />
<HeaderStyle HorizontalAlign="Left" />
</asp:GridView>
</td>
</tr>
<tr>
<td colspan="6" style="height: 417px">
<asp:GridView ID="GridView3" runat="server" AutoGenerateColumns="False"
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -