111,098
社区成员




public void ProcessRequest(HttpContext context)
{
HttpSessionState session = context.Session;
HttpResponse response = context.Response;
HttpServerUtility server = context.Server;
HttpRequest request= context.Request;
if (session[CommonConstant.USER_NAME] == null)
{
response.Redirect("~/login.aspx");
}
String userName = session[CommonConstant.USER_NAME].ToString();
String userRole = session[CommonConstant.USER_ROLE].ToString();
if (!userRole.Equals(CommonConstant.STUDENT))
{
ExceptionReturnObject ero = new ExceptionReturnObject();
ero.ExceptionMsg = "您没有当前操作的权限,请联系管理员";
ero.ExceptionNum = CommonConstant.RIGHTEXCEPTION;
ExceptionHandler.exceptionHandler(ero, session, response);
}
server.Transfer(request.Path, true);
}
context.Server.Transfer(BuildManager.CreateInstanceFromVirtualPath(context.Request.Path, typeof(Page)) as IHttpHandler, true);