<!--Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/--><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>无标题文档</title>
Copy after login
f
<script> function GetXmlHttpObject() { var XMLHttp=null; try { XMLHttp=new XMLHttpRequest(); } catch(e) { try { XMLHttp=new ActiveXObject("Msxml2.XMLHTTP"); } catch(e) { XMLHttp=new ActiveXObject("Microsoft.XMLHTTP"); } } return XMLHttp; } function upload() { var flag=false; var XMLHttp=GetXmlHttpObject(); var url="upload_deal.php"; var dataStr="hour="+document.getElementById("hour").value; XMLHttp.open("POST",url,false); XMLHttp.setRequestHeader("content-type","application/x-www-form-urlencoded"); XMLHttp.send(dataStr); var resTest=XMLHttp.responseText; resTest=resTest.trim(); var response_compent="true"; if(resTest!=response_compent) { document.getElementById("status").innerHTML=resTest; } else flag=true; return flag; }</script>
后台upload_deal.php
PHP code
<!--Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/--> if($_REQUEST['hour']==1) { echo "true"; } else { echo "false"; }
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn