<html>
<head>
<META http-equiv=Content-Language content=zh-cn>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7">
<link rel="stylesheet" type="text/css" href="CSS/Standard.css">
<link rel="stylesheet" type="text/css" href="CSS/Box.css">
<link rel="stylesheet" type="text/css" href="CSS/MiniBase.css">
<link rel="stylesheet" type="text/css" href="CSS/Common.css">
<script> var loadingImage = 'Images/loading.gif'; var closeButton = 'Images/closewindow.gif';</script>
<style>
#overlay{ background-image: url(Images/overlay.png); }
* html #overlay{
	background-color: #333;
	background-color: transparent;
	background-image: url(Images/blank.gif);
	filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="Images/overlay.png", sizingMethod="scale");
	}
</style>
<script type="text/javascript" src="JS/PicBox.js.php"></script>
<script type="text/javascript" src="JS/Jquery.min.js.php"></script>
<script type="text/javascript" src="JS/Jquery.col.js.php"></script>
<script type="text/javascript" src="JS/Jquery.notification.js.php"></script>
<link type="text/css" rel="stylesheet" href="CSS/Notification.css" />

<script type="text/javascript" src="JS/CheckQuestion.js.php"></script>
<link href="CSS/SurveyList.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="JS/Browser.js.php"></script>
<script language=javascript>
function Survey_Form_Submit()
{
	if( Survey_Form_Validator() != false)
	{
		var thisCheckStr = document.Survey_Form.thisCheck.value;
{survey_quota_list}
		if( thisCheckStr != '')
		{
			var thisCheck = thisCheckStr.substr(0,thisCheckStr.length-1).split('|');
			var ajaxURL = 'JS/AjaxCheckTextRepeat.php?qid={surveyID}&qlang={surveyLang}&hash='+thisCheckStr;
			for(var m=0;m<thisCheck.length;m++)
			{
			   var qtnType = thisCheck[m].split('*');
			   switch(qtnType[0])
			   {
					case '4':
					case '23':
					   var objValue = eval('document.Survey_Form.'+qtnType[1]+'.value');
					   ajaxURL += '&'+qtnType[1]+'='+escape(objValue);
					break;
					case '0':
					break;
					case 's1':
					    var theFieldsList = qtnType[3].split('$');
						for(var t=0;t<theFieldsList.length;t++)
						{
						    var objField = eval('document.Survey_Form.'+theFieldsList[t]);
							if( objField != null )
							{
								ajaxURL += '&'+theFieldsList[t]+'='+escape(objField.value);
							}
							else
							{
								ajaxURL += '&'+theFieldsList[t]+'=0';
							}
						}
					break;
					default:
					   var objField = eval('document.Survey_Form.'+qtnType[1]);
					   ajaxURL += '&'+qtnType[1]+'='+getRadioCheckBoxValue(objField);
					break;
 			   }
			}
			var js = document.createElement( "script" ); 
			js.type = "text/javascript" ; 
			js.setAttribute( "src" , ajaxURL);  
			document.body.appendChild(js);
		}
		else
		{
			if( document.getElementById('SurveyNextSubmit') != null ) document.getElementById('SurveyNextSubmit').disabled = true;
			if( document.getElementById('SurveyOverSubmit') != null ) document.getElementById('SurveyOverSubmit').disabled = true;
			if( document.getElementById('SurveyPreSubmit') != null ) document.getElementById('SurveyPreSubmit').disabled = true;
			if( document.getElementById('SurveyCacheSubmit') != null ) document.getElementById('SurveyCacheSubmit').disabled = true;
			document.Survey_Form.submit();
		}
	}
}
function Survey_Form_Validator()
{
   {paperFlagInfoCheck}
   {check_survey_form_list}
}
function Check_Survey_Conditions()
{
   {check_survey_conditions_list}
}
function Init()
{
   Check_Survey_Conditions();
   initLightbox();
   adjustMenuWarpSize();
}
var http_request = false;
function HttpRequest(url)
{
	http_request = false;
	if(window.ActiveXObject)
	{
		try  // IE
		{
			http_request = new ActiveXObject("Msxml2.XMLHTTP");
		}
		catch (e)
		{
			try
			{
				http_request = new ActiveXObject("Microsoft.XMLHTTP");
			}
			catch (e) {}
		}
	}
	else if(window.XMLHttpRequest)
	{
		// Mozilla, Safari,...
		http_request = new XMLHttpRequest();
		if (http_request.overrideMimeType)
		{
			http_request.overrideMimeType('text/xml');
		}
	}
	
	if (!http_request)
	{
		$.notification("Cannot create an XMLHTTP instance");
		return false;
	}
	http_request.onreadystatechange = RtnContents;
	http_request.open('GET', url, true);
	http_request.send(null);
}

function RtnContents()
{
	if (http_request.readyState == 4)
	{
		if(http_request.status == 200)
		{
			if(http_request.responseText == "false")
			   document.getElementById("surveyInfo").innerHTML="<img src=Images/check_no.gif border=0> <span class=red>输入的卷面标识标记已存在&nbsp;</span>";
			else if(http_request.responseText == "true")
			   document.getElementById("surveyInfo").innerHTML="<img src=Images/check_yes.gif border=0> <span class=green>输入的卷面标识标记可使用&nbsp;</span>";
			else if(http_request.responseText == "null") 
			   document.getElementById("surveyInfo").innerHTML="<img src=Images/check_no.gif border=0> <span class=red>输入的卷面标识标记为空&nbsp;</span>";
		}
		else
		{
			$.notification('网络传输问题');
		}
	}
}
</script>

</head>
<body oncontextmenu="return false" style="background-color:#244d8f;">

<div style="line-height:10px">&nbsp;</div>
<div id="menu">
  <span style="float:left;padding-left:26px;"><div class="navmenu">我的问卷 &raquo; 录入纸面问卷数据</div></span>
  <span style="float:right">
  <ul><li>{actionRtnTitle}</li>
      <li class="current"><a href="InputSurveyAnswer.php?surveyID={surveyID}&surveyTitle={survey_URLTitle}&taskID={taskID}">录入纸面数据</a></li>
	  <li style="display:{isAdminRole4}"><a href="ShowInputData.php?surveyID={surveyID}&surveyTitle={survey_URLTitle}">列出录入数据</a></li>
  </ul></span>
</div>

<div class="wrap q_clear" id=wrap>
<div>
<div class=content>
<div class=q_clear id=mysurvey><h1>录入纸面问卷数据</h1><p class=surveynum>[ <span class=red>{resultNum}</span> 数据 ]</p><br/></div>
<div id=myname></div>

<table width=100% cellspacing=0 cellpadding=0>
  <tr><td align=left valign="top">
<!--该调查问卷由科维能动EnableQ在线问卷调查引擎系统生成 -->
<div id="content-wrap">
<div id="content-cont">
<div class="featurebox">
{processBar}
<H4>&nbsp;{surveyTitle}</H4>
<H2>{surveySubTitle}</H2>
<H5>{surveyInfo}</H5>
<form action="" method="post" name="Survey_Form" enctype="multipart/form-data" onsubmit="return false;">
<table bgcolor="#ffffff" cellpadding="0" cellspacing="0" width="100%">
 <tr><td height=5 class="surveyclear">&nbsp;</td></tr>
 {paperFlagInfo}
 <tr><td class="surveybegin">
 <!-- BEGIN QUESTION -->
 <table width="100%" style="display:{isShowQuestion_{questionID}};" class="pertable" id="question_{questionID}">
  {questionList}
  <tr><td height=5 class="surveyclear">&nbsp;</td></tr>
  </table>
 <!-- END QUESTION -->
  </td></tr>
  <tr><td height=5></td></tr>
  <tr align="center"> 
     <td>
        <input name="thisFields" type="hidden" id="thisFields" value="{thisFields}">
        <input name="thisFiles" type="hidden" id="thisFiles" value="{thisFiles}">
        <input name="thisSizes" type="hidden" id="thisSizes" value="{thisSizes}">
        <input name="thisHidden" type="hidden" id="thisHidden" value="{thisHidden}">
        <input name="allHidden" type="hidden" id="allHidden" value="{allHidden}">
        <input name="allFields" type="hidden" id="allFields" value="{allFields}">
		<input name="thisCheck" type="hidden" id="thisCheck" value="{thisCheck}">
		<input name="thisStep" type="hidden" id="thisStep" value="{thisStep}">
		<input name="nextStep" type="hidden" id="nextStep">
		<input name="surveyID" type="hidden" value="{surveyID}">
		<input name="isPublic" type="hidden" value="{isPublic}">
		<input name="taskID" type="hidden" value="{taskID}">
		<input name="passPortType" type="hidden" value="{passPortType}">
		<input name="surveyQuotaFlag" id="surveyQuotaFlag" type="hidden">
		<input name="screeningFlag" id="screeningFlag" type="hidden">
		<input name="surveyQuotaId" id="surveyQuotaId" type="hidden">
		{hiddenFields}
		<input name="Action" type="hidden" id="Action">
		{actionButton}
     </td>
   </tr>
  </form>
</table>
</div></div></div>
<!--该调查问卷由科维能动EnableQ在线问卷调查引擎系统生成 -->
</td></tr></table>
</div></div></div>
<script>Init();</script>
