<?php
	require_once('_approot.php');	

	$username=trim($_GET['username']);
	if(!isset($_SESSION['retryTimes']))
	{$_SESSION['retryTimes']=1;}
?>
<!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><?php echo $engineName?>d</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link type="text/css" rel="stylesheet" href="css/admin.css" />
<link type="text/css" rel="stylesheet" href="css/login.css" />
<STYLE type="text/css">
body {
	background:#fff;
	padding-top:100px;
}
td {
	table-layout:fixed;
	word-break:break-all
}
input {
	FONT-SIZE: 9pt;
	color: #000
}
</STYLE>
<script type="text/JavaScript">
function CheckBrowser() 
{
  var app=navigator.appName;
  var verStr=navigator.appVersion;
  if (app.indexOf('Netscape') != -1) {
	alert(" 你使用的是Netscape浏览器，可能会导致无法使用后台的部分功能。建议您使用 IE6.0 或以上版本。");
  } 
  else if (app.indexOf('Microsoft') != -1) {
	if (verStr.indexOf("MSIE 3.0")!=-1 || verStr.indexOf("MSIE 4.0") != -1 || verStr.indexOf("MSIE 5.0") != -1 || verStr.indexOf("MSIE 5.1") != -1)
	  alert("   您的浏览器版本太低，可能会导致无法使用后台的部分功能。建议您使用 IE6.0 或以上版本。");
  }
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
	d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_validateForm() { //v4.0
  var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
  for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=MM_findObj(args[i]);
	if (val) { nm=val.name; if ((val=val.value)!="") {
	  if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
		if (p<1 || p==(val.length-1)) errors+='- '+nm+' 必须是邮箱地址.\n';
	  } else if (test!='R') { num = parseFloat(val);
		if (isNaN(val)) errors+='- '+nm+' 必须包含数字.\n';
		if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
		  min=test.substring(8,p); max=test.substring(p+1);
		  if (num<min || max<num) errors+='- '+nm+' must contain a number between '+min+' and '+max+'.\n';
	} } } else if (test.charAt(0) == 'R') errors += '- '+nm+' 不能为空：\n'; }
  } if (errors) alert('请更正下列错误:\n'+errors);
  document.MM_returnValue = (errors == '');
}
</script>
</head>
<body onload="document.getElementById('username').focus()"  style=" background:url(images/web_login_bg.jpg) no-repeat center;
background-size: auto auto;height: 100%;overflow: hidden;">
<form action="Checkloginadl.php" method="post" name="form1" >
  <div class="login">
    <div class="message">请先登录</div>
    <div id="darkbannerwrap"></div>
    <input type="text" name="username"  id="username"  value="adlans" size="24" maxlength="20" onMouseOver="this.style.background='#FDE8FE';" onMouseOut="this.style.background='#FFFFFF'"  readonly="readonly" ">
    <hr class="hr15">
    <input type="password" name="password" size="24" maxlength="20"  onMouseOver="this.style.background='#FDE8FE';" onMouseOut="this.style.background='#FFFFFF'" >
        <hr class="hr15">   
         <div>
<?php 	if($_SESSION['retryTimes']>$codeRetryTimes)   //超过规定次数进行验证码验证
															{
														?>
                                                    
<input type="text" name="code" size="10" onmouseover="this.style.background='#FDE8FE';" onmouseout="this.style.background='#FFFFFF'" onfocus="this.select(); "   onclick="this.value=''"  style="width: 70%;margin-top: -26px; color:#999"value="不区分大小写"">
<img src="inc/code.php" border="0" valign="bottom" />
                                                        <?php }?></div>
                                            
    <hr class="hr15">
    <input value="登录" style="width:100%;" type="submit">
    <hr class="hr20">
  </div>
  </form>
</body>
</html>
