using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

public partial class Ex6_6_2_ : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (Session["user"] != null && Session["user"].ToString() != "")
        {
            lblmes.Text = "用户信息如下：<br>用户名：" + Session["user"].ToString() + "<br>密码：" + Session["pwd"].ToString();
            btnquit.Visible = true;
            Session.Timeout = 10;
        }
        else
        {
            lblmes.Text = "你无权进入后台管理！6秒后自动返回上页。<br>或单击下面的链接。";
            hplback.Visible = true;
            Response.Write("<script>setTimeout('window.history.back()', 6000)</script>");
        }
    }
    protected void btnquit_Click(object sender, EventArgs e)
    {
        Session.Abandon();
        Response.Redirect("Ex6-6(2).aspx");
    }
}
