<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib uri="/WEB-INF/taglib/c.tld" prefix="c"%>
<!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>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>网上阅卷系统</title>
<link rel="stylesheet" type="text/css" href="${ctx}/static/mark/style/login.css" />
<link rel="stylesheet" type="text/css" href="${ctx}/static/mark/js/jqueryalert/jquery.alerts.css" />
<script type="text/javascript" src="${ctx}/static/mark/js/jquery-1.8.0.min.js"></script>
<script type="text/javascript" src="${ctx}/static/mark/js/bootstrap.min.js"></script>
<script type="text/javascript" src="${ctx}/static/mark/js/jqueryalert/jquery.alerts.js"></script>
</head>
<body>
<div id="login">
<div id="checkBrower" class="alert alert-block alert-error fade in" style="display: none;">
  <button type="button" class="close" data-dismiss="alert">×</button>
  <h4 class="alert-heading">警告!您的的浏览器版本过低!</h4>
  <p>为了您有更好的体验，请点击下载安装高级浏览器，谢谢！</p>
  <p>
    <a id="download" class="btn btn-success" href="javascript:void(0);">下载</a>
  </p>
</div>
  <div class="grid-946 header-wrap"><a href="http://www.markingcloud.com"><img src="${ctx}/static/mark/images/logo.png" /></a></div>
  <div class="grid-946 banner">
  <div class="login-bgcolor">
  <div class="banner-img">
  <form id="loginFrm" action="${ctx }/mark-login" method="post">
  <div class="login-box ">
    <div class="login-title">
      <h1>科组长/评卷员登录</h1>
    </div>
    <div class=" field field-username">
      <label class="field-lable">用户名：</label>
      <input id="loginName" name="loginName" type="text" class="field-input" placeholder="请输入用户名"/>
    </div>
    <div class=" field field-password" style="margin-bottom:8px;">
      <label class="field-lable">登录密码：</label>
      <input id="password" name="password" type="password" class="field-input" placeholder="请输入密码"/>
    </div>
    <c:if test="${message != null }">
    	<div class="error-box"><i class="icon-exclamation-sign icon-red" style="margin:4px;"></i>${message }</div>
    </c:if>
    <button id="loginButton" class="button button-font">登录</button>
    </div>
    </form>
  </div>
  </div>
  </div>
  <div class="grid-946 footer">
    <p class="footer-font">Copyright © 2013 启明泰和软件服务有限公司</p>
  </div>
</div>
<script type="text/javascript">
$("#loginButton").click(function(){
	  var code = $("#loginName").val();
	  var password = $("#password").val();
	  if(code == null || code.length==0){
		  jAlert('输入用户名', '警告');
		  return false;
	  }else if(password == null || password.length==0){
		  jAlert('请输入密码', '警告');
		  return false;
	  }else{
		  $("#loginFrm").submit();
	  }
});

function detectBrowser(){
	var browser=navigator.appName;
	var b_version=navigator.appVersion;
	var version=parseFloat(b_version);
	if ((browser=="Microsoft Internet Explorer")&& (version<5)){
		$("#checkBrower").show();
	}
}
$(document).ready(function(){
	detectBrowser();
});

$("#download").click(function(){
	window.location.href="${ctx}/static/soft/chrome_installer.exe";
});
</script>
</body>
</html>
