自己写的asp.net网站在URL传值过程中隐藏真正值的方法

//传送值 

protected void btnsend_Click(object sender, EventArgs e)
    {
        string id, disguise, random;
        random = StrOperation.RandString();
        disguise = StrOperation.DisGuise();
        id = StrOperation.DeTransform3(txtID.Text.Trim().ToString());//StrOperation函数为上一篇博客中的方法集
        Response.Redirect("Show.aspx?type=" + id + "&target=" + random + "&id=" + disguise);
    }

//接收值

protected void Page_Load(object sender, EventArgs e)
    {
        if (Request.QueryString["type"] != null && Request.QueryString["type"].ToString() != "")
        {
            string id, code;
            code = Request.QueryString["type"].ToString();
            id = StrOperation.Transform3(code);
            lblID.Text = id;
        }
    }

原文地址:https://www.cnblogs.com/QiuJL/p/4524286.html