<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="../include.jsp"%>
<%
String userName = (String) session.getAttribute("userName_s");
if (!userName.equals("admin")){ 
	response.sendRedirect("error1.jsp");
}
%>
<%try{
	String name = new String(request.getParameter("name").getBytes("ISO8859_1"),"GBK");
	String pass = new String(request.getParameter("pass").getBytes("ISO8859_1"),"GBK");
	String join = new String(request.getParameter("join").getBytes("ISO8859_1"),"GBK");
	int total = Integer.parseInt(request.getParameter("total"));
	int classid = Integer.parseInt(request.getParameter("classid"));
	int login = Integer.parseInt(request.getParameter("login"));
	int id = Integer.parseInt(request.getParameter("id"));

	MasterControl mastercontrol = new MasterControl();
	mastercontrol.setUserName(name);
	mastercontrol.setUserPassword(pass);
	mastercontrol.setTotal(total);
	mastercontrol.setClassid(classid);
	mastercontrol.setJoindate(join);
	mastercontrol.setLoginnum(login);
	mastercontrol.setID(id);
	mastercontrol.modifymaster();%>

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Cache-Control" CONTENT="no-cache">
<META HTTP-EQUIV="Expires" CONTENT="0">
<meta HTTP-EQUIV=REFRESH CONTENT='4; URL=mastermanage.jsp'>
<title>欢迎光临<%=title%></title>
<link rel="stylesheet" href="../css/news.css" type="text/css" media="screen">
</head>
<body>
<TABLE bgColor=<%=tablebgcolor%> border=0 cellPadding=0 cellSpacing=1 width=400 align=CENTER>
	<TR>
		<TD align=middle background=../img/index/topback.gif height=10></TD>
	</TR>
</TABLE>
<TABLE border="0" width=400 align=center cellpadding=0 cellspacing=1  bgcolor=<%=tablebgcolor%>>
	<TR bgcolor=<%=trbgcolor%> height=25><TD align=center><FONT COLOR=red><B>修改管理员信息成功</B></FONT></TD>
	</TR>
	<TR><TD align=center bgColor=<%=tdbgcolor%>><BR>本页面将在<b><span id=yu>3</span><a href=javascript:countDown></a></b>秒后自动返回栏目管理页面，您可以选择以下操作：<BR><BR>
	<li><a href="../index.jsp">返回首页</a></li><br>
	<li><a href='editmaster.jsp?id=<%=id%>'>继续修改管理员信息</a></li><br>
	<li><a href="mastermanage.jsp">返回管理页面</a></li>
	</TD></TR>
</TABLE>

	<%@ include file="../inc/tail.jsp"%>
	<script>
	function 
	countDown(secs){yu.innerText=secs;if(--secs>0)setTimeout("countDown("+secs+")",1000);}countDown(3);
	</script>
	<%
	}
	catch(Exception e){
	out.println("错误信息:"+e.getMessage());
	}%>