填空的标记是 [q][/q]
lms = "";
rms = 0;
pms = "";
qtinfo = {"1":"单选题","2":"多选题","3":"判断题","4":"填空题","5":"简答题","6":"论述题"};
quest = "";
qtv = "";
qfv = "";
MyUtil={};
function obj2str(o){
var r = [];
if(typeof o =="string") return "\""+o.replace(/([\'\"\\])/g,"\\$1").replace(/(\n)/g,"\\n").replace(/(\r)/g,"\\r").replace(/(\t)/g,"\\t")+"\"";
if(typeof o =="undefined") return "";
if(typeof o == "object"){
if(o===null) return "null";
else if(!o.sort){
for(var i in o)
r.push('"'+i+"\":"+obj2str(o[i]))
r="{"+r.join()+"}"
}else{
for(var i =0;i<o.length;i++)
r.push(obj2str(o[i]))
r="["+r.join()+"]"
}
return r;
}
return o.toString();
}
//考试初始化
function get_paper(){
$.get("student!examine.do",{"ajax":"yes","rad":Math.random()},function(data){
if(data == 'nodata'){
alert('暂时没有试卷!');
return false;
}
data = eval('('+unescape(data.replace(/\\u/g,'%u'))+')');
lms = data.paper.totaltime;
pms = data.paper.postafter;
quest = data.question;
make_sntree(quest); //生成序列树
goto_topic(quest[0]['questionorder']); //生成第一道题
update_already(0,quest.length); //更新已做未做
setInterval("set_last_time()",1000); //设置倒计时
});
}
//传入时间戳,显示倒计时
function get_last_time(ms){
var s = ms % 60; //得到剩余秒
var m = (ms-s) / 60; //得到剩余分
s = s + '';
s = (s.length == 1) ? '0'+s : s ;
return {"m":m,"s":s}
}
//更新倒计时
function set_last_time(){
lms--;
if(lms == 0){
submital();
}
rms++;
ems = get_last_time(lms);
$("#lasttime").html(ems.m+"分"+ems.s+"秒");
}
//生成序列树
function make_sntree(quest){
if(quest == undefined){
alert("没有获取到考题!");
return false;
}
for(i=0;i<quest.length;i++){
var qsn = quest[i].questionorder; //得到题序号(qsn)
var qid = quest[i].qid; //得到题号(qid)
var qtype = quest[i].type; //题型标识(qtype)
var qtypeinfo = qtinfo[quest[i].type]; //题型说明(qtypeinfo)
if(!$("#qt_"+qtype).html() && !$("#tn_"+qtype).html()){
$("#tsn").append('<li class="active" id="qt_'+qtype+'"><a>'+qtypeinfo+'</a><div id="tn_'+qtype+'"><a class="qe1" id="sn_'+qsn+'" onclick="goto_topic('+qsn+');">'+qsn+'</a></div></li><br><br>');
}else{
$("#tn_"+qtype).append('<a class="qe1" id="sn_'+qsn+'" onclick="goto_topic('+qsn+');">'+qsn+'</a>');
}
}
}
//更新已做未做
function update_already(qt,qf){
if(qt == undefined && qf == undefined){
var r=0;
var c=quest.length;
for(i=0;i<c;i++){
if(quest[i].isalready == '1'){
r++;
}
}
qtv = r;
qfv = c-r;
}else{
qtv = qt;
qfv = qf;
}
$("#qt").html(qtv);
$("#qf").html(qfv);
}
function FCKeditor_OnComplete( editorInstance )
{
editorInstance.Events.AttachEvent( 'OnBlur', set_answer );
}
//根据题ID生成并跳到题目
function goto_topic(qsn){
var qid = quest[qsn-1]['qid'];
var qtype = quest[qsn-1]['type'];
var qinfo = qtinfo[qtype];
var score = quest[qsn-1]['questionscore'];
var sa = "";
var qcount = quest.length;
var psn = parseInt(qsn)-1;
var nsn = parseInt(qsn)+1;
var ranswer = quest[psn]['rightanswer'];
var re = /\[q\].*?\[\/q\]/g;
$("#my_answer").hide();
$.get("student!question.do",{"ajax":"yes","qid":qid,"rad":Math.random()},function(data){
if(data == 'noquest'){
alert('没有找到考题!');
return false;
}
data = eval('('+unescape(data.replace(/\\u/g,"%u"))+')');
var ds = data.selectanswer;
var title = re.test(data.title) ? data.title.replace(re,' <input type="text" size="4" style="border:1px solid #eeeeee;" onblur="set_answer('+qsn+',document.getElementById(\'q_title\'),\''+qtype+'\')"> ') : data.title ;
//alert(title);
var ret1 = /(<p><span.*?>)\d+[\..\,,。、](.*?)(<\/span>)<\/p>/;
var ret2 = /(<p>)\d+[\..\,,。、](.*?)<\/p>/;
var ret3 = /^(\d+[\..\,,。、])(.*?)/;
if(ret1.test(title)){
title = title.replace(ret1,"$1$2$3");
}
if(ret2.test(title)){
title = title.replace(ret2,"$1$2$3");
}
if(ret3.test(title)){
title = title.replace(ret3,"$2");
}
if(isinarr(new Array('1','2','3'),qtype)){
title += '<span id="input_answer" style="font-weight:bold;color:green;">['+quest[parseInt(qsn)-1]['studentanswer']+']</span>';
}
$("#q_sn").html('第'+qsn+'题 ('+qinfo+')');
$("#q_title").html(title);
$("#q_title").html(title+' ('+score+'分)');
if(qsn == '1'){
$("#goto_page").html(' <img src="image/nq.gif" onclick="goto_topic(\''+nsn+'\');" style="cursor:pointer;"> ');
}else if(qsn == qcount){
$("#goto_page").html(' <img src="image/pq.gif" onclick="goto_topic(\''+psn+'\');" style="cursor:pointer;">');
}else{
$("#goto_page").html(' <img src="image/pq.gif" onclick="goto_topic(\''+psn+'\');" style="cursor:pointer;"> <img src="image/nq.gif" onclick="goto_topic(\''+nsn+'\');" style="cursor:pointer;">');
}
switch(qtype){
case "1":
case "3":
for(i=0;i<ds.length;i++){
k = ds[i].substr(0,1);
sed = k == quest[qsn-1]['studentanswer'] ? "checked" : "" ;
sa += '<input type="radio" name="an_'+qid+'" value="'+k+'" onclick="set_answer('+qsn+',this,\''+qtype+'\')" '+sed+' > '+ds[i]+'<br><br>';
}
break;
case "2":
for(i=0;i<ds.length;i++){
k = ds[i].substr(0,1);
sed = (quest[qsn-1]['studentanswer'].indexOf(k) < 0) ? "" : "checked" ;
sa += '<input type="checkbox" name="an_'+qid+'" value="'+k+'" onclick="set_answer('+qsn+',this,\''+qtype+'\')" '+sed+' > '+ds[i]+'<br><br>';
}
break;
case "4":
val = quest[qsn-1]['studentanswer'].split(",") ;
$('input').each(function(i){
$(this).attr('value',val[i]);
});
break;
case "5":
case "6":
$("#my_answer").show();
val = quest[qsn-1]['studentanswer'].length ? quest[qsn-1]['studentanswer'] : "";
$("#my_answer").html('<textarea id="mycontent" style="width:480px;height:200px;" onblur="set_answer('+qsn+',this,\''+qtype+'\')">'+val+'</textarea>');
//$("#my_answer").html('<textarea id="mycontent" style="width:480px;height:200px;" >'+val+'</textarea>');
//XXX
$(function() {
if (CKEDITOR.instances['mycontent']) {
CKEDITOR.remove(CKEDITOR.instances['mycontent']);
}
$('#mycontent').ckeditor();
CKEDITOR.instances.mycontent.on('blur', function() {
var obj = new Object();
obj.value = CKEDITOR.instances.mycontent.getData();
set_answer(qsn,obj,qtype);
});
});
break;
}
$("#select_answer").html(sa);
});
document.documentElement.scrollTop=0;
}
//答题方法
//var anarr = new Array();
function set_answer(qsn,obj,qtype){
//将答案更新到全局变量里
switch(qtype){
case "1":
case "3":
case "5":
case "6":
quest[parseInt(qsn)-1]['studentanswer'] = $.trim(obj.value);
break;
case "2":
if(obj.checked){
var anw = quest[parseInt(qsn)-1]['studentanswer'].indexOf(obj.value) < 0 ? obj.value : "" ;
quest[parseInt(qsn)-1]['studentanswer'] += anw;
quest[parseInt(qsn)-1]['studentanswer'] = str_sort(quest[parseInt(qsn)-1]['studentanswer']);
}else{
quest[parseInt(qsn)-1]['studentanswer'] = quest[parseInt(qsn)-1]['studentanswer'].replace(obj.value,"");
}
break;
case "4":
var anobj = $("#"+obj.id+" input");
var anarr = new Array();
for(i=0;i<anobj.length;i++){
anarr.push(anobj[i].value);
}
quest[parseInt(qsn)-1]['studentanswer'] = anarr.toString();
break;
}
if(isinarr(new Array('1','2','3'),qtype)){
var anreg = /(<span\s+.*?id=input_answer.*?>\[).*?(\]<\/span>)/i;
//alert(navigator.userAgent);
if(navigator.userAgent.indexOf("MSIE") > 1){
anreg = /(<span\s+.*?id=input_answer.*?>\[).*?(\]<\/span>)/i;
}else if(navigator.userAgent.indexOf("AppleWebKit") >1){
anreg = /(<span\s+.*?id=\"input_answer\".*?>\[).*?(\]<\/span>)/i;
}else if(navigator.userAgent.indexOf("Firefox") > 1){
anreg = /(<span\s+.*?id=\"input_answer\".*?>\[).*?(\]<\/span>)/i;
}
var qhtml = $("#q_title").html();
$("#q_title").html(qhtml.replace(anreg,"$1"+quest[parseInt(qsn)-1]['studentanswer']+"$2"));
}
quest[parseInt(qsn)-1]['isalready'] = '1'; //设置为已答
//更新到服务器,未做。。。
update_already();
set_progress();
$("#sn_"+qsn).attr("class","qe2");
}
//交卷方法
function submital(){
qdata = obj2str(quest);
$("#last_answer").attr("value",qdata);//填充内容
if(window.onbeforeunload = null){
document.exam.submit();
}
document.exam.submit();
}
//放弃考试提示
function exam_exit(){
$("#dialog-exit").dialog("open");
return false;
}
//交卷前的提示程序 TODO
function submittest(){
// var pfv = parseInt($("#pf").html());
var pfv = 5;
if(rms < pfv){
$("#dialog-time").html("考试时间不足"+pfv+"秒,不能交卷!");
$("#dialog-time").dialog("open");
}else{
var qf = parseInt($("#qf").html());
if(qf>0 && parseInt(lms)){
window.onunload= null;
$("#dialog-confirm").html("您还有"+qf+"道试题未做,是否继续交卷!");
$("#dialog-confirm").dialog("open");
}else{
return submital();
}
}
}
//生成空进度条
function make_pic(){
var mpic = "";
for(i=1;i<=20;i++){
mpic += '<img class="epg" id="pg_'+i+'" src="image/jd_gray.gif" >';
}
$("#exam_progress").html(mpic);
}
//设置进度条进度
function set_progress(){
var qt = parseInt($("#qt").html()); //得到已做题数
var qf = parseInt($("#qf").html()); //得到未做题数
var qc = qt+qf; //得到总共题数
var pv = Math.round(20 * (qt / qc)); //得到进度值
$(".epg").attr("src","image/jd_gray.gif");
for(i=1;i<=pv;i++){
$("#pg_"+i).attr("src","image/jd_blue.gif");
}
}
//是否交卷
function issubmit(){
if(!confirm("所有考题已做完,是否立即交卷?")){
return false;
}else{
submital();
}
}
function test(){
var obj = document.getElementById("dialog-confirm").style;
$.each(obj,function(i,n){
alert(i+','+n);
});
}
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/commons/taglibs.jsp"%>
<%
String path = request.getContextPath();
%>
<script src="<%=path%>/statics/js/common/common.js"
type="text/javascript"></script>
<script src="<%=path%>/editor/ckeditor/ckeditor.js"
type="text/javascript"></script>
<script src="<%=path%>/editor/ckeditor/adapters/jquery.js"
type="text/javascript"></script>
<script type="text/javascript">
var app_path="<%=path%>";
var mainpage = false;
</script>
<META HTTP-EQUIV="pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Cache-Control" CONTENT="no-cache, must-revalidate">
<META HTTP-EQUIV="expires" CONTENT="Wed, 26 Feb 1997 08:21:57 GMT">
<script language="JavaScript" type="text/javascript" src="js/jquery-ui-1.7.1.custom.min.js"></script>
<script language="JavaScript" type="text/javascript" src="js/public.js"></script>
<script language="JavaScript" type="text/javascript" src="js/fck_script_exam.js"></script>
<style type="text/css">
@import url(template/default/style.css);
@import url(template/default/jquery-ui-1.7.2.custom.css);
.side { float: left; width: 130px; margin-right:10px; }
/*粗边框区域*/
.block { margin-bottom: 10px; padding: 0.5em 1em; border: 1px solid #EFF5F8; display:inline-block;}
.block h2 { margin: 0.5em 0; color: #363636; font-size: 1.17em; }
.block p { margin: 0.5em 0; }
.side .block li { margin: 0.5em 0; clear:both; }
</style>
<link rel="shortcut icon" href="image/favicon.ico">
<link rel="edituri" type="application/rsd+xml" title="rsd" href="xmlrpc.php?rsd=">
<script language="JavaScript" type="text/javascript">
window.onbeforeunload = CloseEvent;
var DispClose = true;
function CloseEvent()
{
if(navigator.userAgent.indexOf("IE")>0) {
if (DispClose){
submittest();
}
}
if(isFirefox=navigator.userAgent.indexOf("Firefox")>0){
if (DispClose){
return "是否离开当前页面?";
}
}
}
window.onunload= UnLoadEvent;
function UnLoadEvent(){
if(isFirefox=navigator.userAgent.indexOf("Firefox")>0){
DispClose = false;
//在这里处理关闭页面前的动作
window.close();
}
}
</script>
<script language="Javascript">
document.oncontextmenu = function() {
return false;
};
document.ondragstart = function() {
return false;
};
document.onselectstart = function() {
return false;
};
document.onbeforecopy = function() {
return false;
};
function DisableF5() {
with (event) {
// F5 and Ctrl+R
if (keyCode == 116 || (ctrlKey && keyCode == 82)) {
event.keyCode = 0;
event.cancelBubble = true;
return false;
}
}
}
document.onkeydown = DisableF5;
var check=function(e){
e=e||window.event;
//alert(e.which||e.keyCode);
if((e.which||e.keyCode)==116){
if(e.preventDefault){
e.preventDefault();}
else{event.keyCode = 0;
e.returnValue=false;}
}
};
if(document.addEventListener){
document.addEventListener("keydown",check,false);
}
else{
document.attachEvent("onkeydown",check);
}
</script>
<style type="text/css" charset="utf-8">/* See license.txt for terms of usage */
/** reset styling **/
.firebugResetStyles {
z-index: 2147483646 !important;
top: 0 !important;
left: 0 !important;
display: block !important;
border: 0 none !important;
margin: 0 !important;
padding: 0 !important;
outline: 0 !important;
min-width: 0 !important;
max-width: none !important;
min-height: 0 !important;
max-height: none !important;
position: fixed !important;
-moz-transform: rotate(0deg) !important;
-moz-transform-origin: 50% 50% !important;
-moz-border-radius: 0 !important;
-moz-box-shadow: none !important;
background: transparent none !important;
pointer-events: none !important;
}
.firebugBlockBackgroundColor {
background-color: transparent !important;
}
.firebugResetStyles:before, .firebugResetStyles:after {
content: "" !important;
}
/**actual styling to be modified by firebug theme**/
.firebugCanvas {
display: none !important;
}
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
.firebugLayoutBox {
width: auto !important;
position: static !important;
}
.firebugLayoutBoxOffset {
opacity: 0.8 !important;
position: fixed !important;
}
.firebugLayoutLine {
opacity: 0.4 !important;
background-color: #000000 !important;
}
.firebugLayoutLineLeft, .firebugLayoutLineRight {
width: 1px !important;
height: 100% !important;
}
.firebugLayoutLineTop, .firebugLayoutLineBottom {
width: 100% !important;
height: 1px !important;
}
.firebugLayoutLineTop {
margin-top: -1px !important;
border-top: 1px solid #999999 !important;
}
.firebugLayoutLineRight {
border-right: 1px solid #999999 !important;
}
.firebugLayoutLineBottom {
border-bottom: 1px solid #999999 !important;
}
.firebugLayoutLineLeft {
margin-left: -1px !important;
border-left: 1px solid #999999 !important;
}
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
.firebugLayoutBoxParent {
border-top: 0 none !important;
border-right: 1px dashed #E00 !important;
border-bottom: 1px dashed #E00 !important;
border-left: 0 none !important;
position: fixed !important;
width: auto !important;
}
.firebugRuler{
position: absolute !important;
}
.firebugRulerH {
top: -15px !important;
left: 0 !important;
width: 100% !important;
height: 14px !important;
background: url("data:image/png,%89PNG%0D%0A%1A%0A%00%00%00%0DIHDR%00%00%13%88%00%00%00%0E%08%02%00%00%00L%25a%0A%00%00%00%04gAMA%00%00%D6%D8%D4OX2%00%00%00%19tEXtSoftware%00Adobe%20ImageReadyq%C9e%3C%00%00%04%F8IDATx%DA%EC%DD%D1n%E2%3A%00E%D1%80%F8%FF%EF%E2%AF2%95%D0D4%0E%C1%14%B0%8Fa-%E9%3E%CC%9C%87n%B9%81%A6W0%1C%A6i%9A%E7y%0As8%1CT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AATE9%FE%FCw%3E%9F%AF%2B%2F%BA%97%FDT%1D~K(%5C%9D%D5%EA%1B%5C%86%B5%A9%BDU%B5y%80%ED%AB*%03%FAV9%AB%E1%CEj%E7%82%EF%FB%18%BC%AEJ8%AB%FA'%D2%BEU9%D7U%ECc0%E1%A2r%5DynwVi%CFW%7F%BB%17%7Dy%EACU%CD%0E%F0%FA%3BX%FEbV%FEM%9B%2B%AD%BE%AA%E5%95v%AB%AA%E3E5%DCu%15rV9%07%B5%7F%B5w%FCm%BA%BE%AA%FBY%3D%14%F0%EE%C7%60%0EU%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5JU%88%D3%F5%1F%AE%DF%3B%1B%F2%3E%DAUCNa%F92%D02%AC%7Dm%F9%3A%D4%F2%8B6%AE*%BF%5C%C2Ym~9g5%D0Y%95%17%7C%C8c%B0%7C%18%26%9CU%CD%13i%F7%AA%90%B3Z%7D%95%B4%C7%60%E6E%B5%BC%05%B4%FBY%95U%9E%DB%FD%1C%FC%E0%9F%83%7F%BE%17%7DkjMU%E3%03%AC%7CWj%DF%83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0j%94%07%A0%C7%A0%AB%FD%B5%3F%A0%F7%03T%3Dy%D7%F7%D6%D4%C0%AAU%D2%E6%DFt%3F%A8%CC%AA%F2%86%B9%D7%F5%1F%18%E6%01%F8%CC%D5%9E%F0%F3z%88%AA%90%EF%20%00%00%00%00%00%00%00%00%00%C0%A6%D3%EA%CFi%AFb%2C%7BB%0A%2B%C3%1A%D7%06V%D5%07%A8r%5D%3D%D9%A6%CAu%F5%25%CF%A2%99%97zNX%60%95%AB%5DUZ%D5%FBR%03%AB%1C%D4k%9F%3F%BB%5C%FF%81a%AE%AB'%7F%F3%EA%FE%F3z%94%AA%D8%DF%5B%01%00%00%00%00%00%00%00%00%00%8E%FB%F3%F2%B1%1B%8DWU%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*UiU%C7%BBe%E7%F3%B9%CB%AAJ%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5J%95*U%AAT%A9R%A5*%AAj%FD%C6%D4%5Eo%90%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5%86%AF%1B%9F%98%DA%EBm%BBV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%ADV%AB%D5j%B5Z%AD%D6%E4%F58%01%00%00%00%00%00%00%00%00%00%00%00%00%00%40%85%7F%02%0C%008%C2%D0H%16j%8FX%00%00%00%00IEND%AEB%60%82") repeat-x !important;
border-top: 1px solid #BBBBBB !important;
border-right: 1px dashed #BBBBBB !important;
border-bottom: 1px solid #000000 !important;
}
.firebugRulerV {
top: 0 !important;
left: -15px !important;
width: 14px !important;
height: 100% !important;
background: url("data:image/png,%89PNG%0D%0A%1A%0A%00%00%00%0DIHDR%00%00%00%0E%00%00%13%88%08%02%00%00%00%0E%F5%CB%10%00%00%00%04gAMA%00%00%D6%D8%D4OX2%00%00%00%19tEXtSoftware%00Adobe%20ImageReadyq%C9e%3C%00%00%06~IDATx%DA%EC%DD%D1v%A20%14%40Qt%F1%FF%FF%E4%97%D9%07%3BT%19%92%DC%40(%90%EEy%9A5%CB%B6%E8%F6%9Ac%A4%CC0%84%FF%DC%9E%CF%E7%E3%F1%88%DE4%F8%5D%C7%9F%2F%BA%DD%5E%7FI%7D%F18%DDn%BA%C5%FB%DF%97%BFk%F2%10%FF%FD%B4%F2M%A7%FB%FD%FD%B3%22%07p%8F%3F%AE%E3%F4S%8A%8F%40%EEq%9D%BE8D%F0%0EY%A1Uq%B7%EA%1F%81%88V%E8X%3F%B4%CEy%B7h%D1%A2E%EBohU%FC%D9%AF2fO%8BBeD%BE%F7X%0C%97%A4%D6b7%2Ck%A5%12%E3%9B%60v%B7r%C7%1AI%8C%BD%2B%23r%00c0%B2v%9B%AD%CA%26%0C%1Ek%05A%FD%93%D0%2B%A1u%8B%16-%95q%5Ce%DCSO%8E%E4M%23%8B%F7%C2%FE%40%BB%BD%8C%FC%8A%B5V%EBu%40%F9%3B%A72%FA%AE%8C%D4%01%CC%B5%DA%13%9CB%AB%E2I%18%24%B0n%A9%0CZ*Ce%9C%A22%8E%D8NJ%1E%EB%FF%8F%AE%CAP%19*%C3%BAEKe%AC%D1%AAX%8C*%DEH%8F%C5W%A1e%AD%D4%B7%5C%5B%19%C5%DB%0D%EF%9F%19%1D%7B%5E%86%BD%0C%95%A12%AC%5B*%83%96%CAP%19%F62T%86%CAP%19*%83%96%CA%B8Xe%BC%FE)T%19%A1%17xg%7F%DA%CBP%19*%C3%BA%A52T%86%CAP%19%F62T%86%CA%B0n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%96%CA%A0e%B6h%D1%A2E%8B%16-%95a%B6h%D1%A2E%8B%16-%95A%CBl%D1%A2E%8B%16-%95A%CBl%D1%A2E%8B%16-Z*%C3l%D1%A2E%8B%16-Z*%83%96%D9%A2E%8B%16-Z*%83%96%D9%A2E%8B%16-Z%B4T%86%D9%A2E%8B%16-Z%B4T%06-%B3E%8B%16-Z%B4T%06-%B3E%8B%16-Z%B4h%A9%0C%B3E%8B%16-Z%B4h%A9%0CZf%8B%16-Z%B4h%A9%0CZf%8B%16-Z%B4h%D1R%19f%8B%16-Z%B4h%D1R%19%B4%CC%16-Z%B4h%D1R%19%B4%CC%16-Z%B4h%D1%A2%A52%CC%16-Z%B4h%D1%A2%A52h%99-Z%B4h%D1%A2%A52h%99-Z%B4h%D1%A2EKe%98-Z%B4h%D1%A2EKe%D02%5B%B4h%D1%A2EKe%D02%5B%B4h%D1%A2E%8B%96%CA0%5B%B4h%D1%A2E%8B%96%CA%A0e%B6h%D1%A2E%8B%96%CA%A0e%B6h%D1%A2E%8B%16-%95a%B6h%D1%A2E%8B%16-%95A%CBl%D1%A2E%8B%16-%95A%CBl%D1%A2E%8B%16-Z*%C3l%D1%A2E%8B%16-Z*%83%96%D9%A2E%8B%16-Z*%83%96%D9%A2E%8B%16-Z%B4T%86%D9%A2E%8B%16-Z%B4T%06-%B3E%8B%16-Z%B4%AE%A4%F5%25%C0%00%DE%BF%5C'%0F%DA%B8q%00%00%00%00IEND%AEB%60%82") repeat-y !important;
border-left: 1px solid #BBBBBB !important;
border-right: 1px solid #000000 !important;
border-bottom: 1px dashed #BBBBBB !important;
}
.overflowRulerX > .firebugRulerV {
left: 0 !important;
}
.overflowRulerY > .firebugRulerH {
top: 0 !important;
}
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
.fbProxyElement {
position: fixed !important;
pointer-events: auto !important;
}</style>
<body>
<div id="dialog-confirm" title="您确定要继续提交?"></div>
<div id="dialog-exit" title="您确定要放弃考试?">是否要放弃考试,如果现在放弃,将不记录考试成绩,并且考试次数将减少一次!</div>
<div id="dialog-time" title="限制时间内不能提交考试"></div>
<div id="dialog-goto" title="提示!">检测到您将要退出考试!</div>
<div id="wrap">
<div id="main">
<div class="exam_logo"><img src="image/exam_logo.png" /></div>
<div class="side">
<div class="block style1" style="min-height:520px;background:#DFEAD8;">
<h2>题目序列</h2>
说明:试题序号的底色为白色时表示该题未答,为蓝色时表示该题已答。
<hr>
<ul class="folder" style="width:102px;" id="tsn">
</ul>
</div>
</div>
<div id="mainarea">
<span id="pid" style="display:none;">{$pid}</span>
<span id="pf" style="display:none;">{$_SCONFIG['postafter']}</span>
<div id="content" style="width:800px;">
<div class="feed" >
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="460" height="22" colspan="2"><strong>考试科目:<span class="video h2"><%=request.getParameter("pname") %></span></strong></td>
<td rowspan="3" align="center">考试剩余时间:<span id="lasttime" style="color:red;font-size:14px;font-weight:bold;"></span><br><br>
<!-- <a href="javascript:windows.close()" style="text-decoration:underline;">放弃考试</a> -->
<a href="javascript:submittest()" class="exam_commit" ></a></td>
</tr>
<tr>
<td width="460" height="22" colspan="2"><div id="jdt">考试进度:<span id="exam_progress" ></span></div></td>
</tr>
<tr>
<td height="22" colspan="2">已答试题:<span id="qt" style="color:red;"></span> 未答试题:<span id="qf" style="color:red;"></span> </td>
<td align="center"></td>
</tr>
</table>
</div>
<div id="q_content" style="border:1px solid #eeeeee;padding:10px;display:inline-block;">
<div id="q_sn"> </div>
<div id="q_title" style="margin-left:50px;"></div>
<div id="select_answer" style="margin-left:50px;"></div>
<div id="my_answer" style="margin-left:50px;">
</div>
<div>
<!-- <form name="exam" action="teacher!studentCommitPaper.do" method="POST" > -->
<form name="exam" action="teacher!submit.do" method="POST" >
<input type="text" name="quest" id="last_answer" style="display:none;" ></input>
</form>
</div>
<hr style="border:1px solid #eeeeee;">
<table style="margin-left:50px;"><tr><td id="goto_page"></td></tr></table>
</div>
</div>
<script language="JavaScript" type="text/javascript">
var pid = $("#pid").html();
get_paper();
$(function(){
$("#dialog-confirm").dialog({
autoOpen:false,
resizable: false,
width:200,
height:140,
modal: true,
buttons: {
继续答题: function() {
$(this).dialog('close');
return false;
},
确认交卷: function() {
window.onbeforeunload = null;
submital();
$(this).dialog('close');
}
}
});
$("#dialog-exit").dialog({
autoOpen:false,
resizable: false,
width:320,
height:150,
modal: true,
buttons: {
取消: function() {
$(this).dialog('close');
return false;
},
确定: function() {
unclose();
window.location = "space.php";
$(this).dialog('close');
}
}
});
$("#dialog-time").dialog({
autoOpen:false,
resizable: false,
width:320,
height:150,
modal: true,
buttons: {
确定: function() {
$(this).dialog('close');
}
}
});
$("#dialog-goto").dialog({
autoOpen:false,
resizable: false,
width:320,
height:150,
modal: true,
buttons: {
继续考试: function() {
$(this).dialog('close');
}
}
});
make_pic();
});
</script>
</body>