+<%-- 写一个登录页面,有用户名和密码,点击登录,跳转到登录成功页面,
+登录成功页面显示“欢迎你,张三,你的密码是:123”(h1效果)
+
+登录按钮有两个,一个是Post请求,一个是Get请求。
+在登录成功页面,需判断请求的方式,如果是Post,
+ 请用Post对应的方式获取Request数据,如果是Get,请用Get对应的方式获取Request数据。
+--%>
+ 用户名:
+
+ 密码:
+
+
+
+
+
+
跳转
+
跳转3
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..dc958f511bd5649662cd6bdd7ec1669aad057c69
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.cs"
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ string userName = username.Text;
+ string Pwd = pwd.Text;
+
+ //get方式发送请求,就是把参数放在url里
+ //请求转发
+ Response.Redirect($"WebForm4.aspx?userName={userName}&pwd={pwd}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..33be4f21a47c85c635d750c4b30b7f72b4458771
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.designer.cs"
@@ -0,0 +1,80 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// username 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox username;
+
+ ///
+ /// pwd 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox pwd;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+
+ ///
+ /// HyperLink1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.HyperLink HyperLink1;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..69f627c1c52c3a70d955286f2716c20fc01835bd
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..94911430a760984d3581caf2c398c8316944247c
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string userName = Request.Form["UserName"];
+ string pwd = Request.Form["Pwd"];
+
+ string userName1 = Request.Params["UserName"];
+ string pwd1 = Request.Params["Pwd"];
+
+ string userName2 = Request.QueryString["UserName"];
+ string pwd2 = Request.QueryString["Pwd"];
+
+ string userName3 = "";
+ string pwd3 = "";
+ if (PreviousPage != null)
+ {
+ TextBox userNameBox = (TextBox)PreviousPage.FindControl("UserName");
+ TextBox pwdNameBox = (TextBox)PreviousPage.FindControl("Pwd");
+ if (userName != null)
+ {
+ userName3 = userNameBox.Text;
+ }
+ if (pwdNameBox != null)
+ {
+ pwd3 = pwdNameBox.Text;
+ }
+ }
+
+ Response.Write("Request.Form ==> " + userName + "
");
+ Response.Write("Request.Form ==> " + pwd + "
");
+
+ Response.Write("Request.Params ==> " + userName1 + "
");
+ Response.Write("Request.Params ==> " + pwd1 + "
");
+
+ Response.Write("Request.QueryString ==> " + userName2 + "
");
+ Response.Write("Request.QueryString ==> " + pwd2 + "
");
+
+ Response.Write("PreviousPage ==> " + userName3 + "
");
+ Response.Write("PreviousPage ==> " + pwd3 + "
");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..52a837c60648ba1b53ccbc830a5a6ef2a4b20f5a
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm3.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm3.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..c505de55e064a064c2a184d75bca8ed5b6fe8612
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm3.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm3.aspx.cs" Inherits="WebApplication1.WebForm3" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm3.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm3.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5ed015b8658ebc878f3750a18cd7294981ae4778
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm3.aspx.cs"
@@ -0,0 +1,17 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm3 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm3.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm3.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c7b20975af550ece04cd45fbf4a281e6f44a2c12
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm3.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+//
+// 此代码由工具生成。
+//
+// 对此文件的更改可能会导致不正确的行为,并且如果
+// 重新生成代码,这些更改将会丢失。
+//
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm3
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..f38b1f692145644f48b014d30957cffb5ed2a96f
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx"
@@ -0,0 +1,20 @@
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..a8a468bee762717920fb8e59567c8cfdf0d85b91
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx.cs"
@@ -0,0 +1,25 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string a = TextBox1.Text;
+ string b = TextBox2.Text;
+
+ Response.Redirect($"WebForm2.aspx?a={a}&b={b}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..12ae6108a6ac6eb8f0bb7439f8b7970a6a7dbc04
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..cb5c820eba5b1da27f6cd32bcab043f2d8ef4e3c
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm2.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..874f37ee69644cd5831505373e4a3cac2aa1f8c8
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm2.aspx.cs"
@@ -0,0 +1,25 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string a1 = Request.Form["TextBox1"];
+ string b1 = Request.Form["TextBox2"];
+
+ Response.Write($"Post
欢迎你,{a1},你的密码为{b1}
");
+
+
+ string a2 = Request.QueryString["a"];
+ string b2 = Request.QueryString["b"];
+ Response.Write($"Get
欢迎你,{a2},你的密码为{b2}
");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm2.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..0c9ff10cac501bfdf4d76f7ea9e564b0da06b315
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm2.aspx.designer.cs"
@@ -0,0 +1,25 @@
+//------------------------------------------------------------------------------
+//
+// 此代码由工具生成。
+//
+// 对此文件的更改可能会导致不正确的行为,并且如果
+// 重新生成代码,这些更改将会丢失。
+//
+//------------------------------------------------------------------------------
+
+
+namespace WebApplication2
+{
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..398b651b9269f5a210be5d63fc231e2dc2008dba
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication3.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..9989900b55071ee9c76c519bf1992aa06224d578
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.cs"
@@ -0,0 +1,33 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ int a;
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string userName = UserName.Text;
+ string pwd = Pwd.Text;
+ Response.Redirect($"WebForm2.aspx?userName={userName}&pwd={pwd}");
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string userName1 = UserName.Text;
+ string pwd1 = Pwd.Text;
+ Response.Redirect($"WebForm3.aspx?userName={userName1}&pwd={pwd1}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..9af56d448ee3e6d283594a3f2bb3789f291a42d7
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication3.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..d66e66b8dda3875314d4f30be811464c28c4dd36
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx.cs"
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ string userName = Request.Form["UserName"];
+ string pwd = Request.Form["Pwd"];
+ Response.Write("账号:" + userName + "密码是" + pwd);
+
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm3.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm3.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..3fd463664b9b833b64ad683323270876cd8f8236
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm3.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm3.aspx.cs" Inherits="WebApplication3.WebForm3" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm3.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm3.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f73387a1a7555c8d80c31be4f68f95b106c2e098
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm3.aspx.cs"
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class WebForm3 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string userName1 = Request.Params["UserName"];
+ string pwd1 = Request.Params["Pwd"];
+ Response.Write("账号 " + userName1 + "
");
+ Response.Write("密码 " + pwd1 + "
");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/.keep" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..5f5d368dbd17cf30efda93f9023736e40ec0911c
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx"
@@ -0,0 +1,25 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..12dc50471f00b460071a1c936cc8aa3cd033783b
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx.cs"
@@ -0,0 +1,27 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ //string name = Request.Form["name"];
+ //string password = Request.Form["password"];
+ //Response.Redirect("WebForm1.aspx?name=" + name + "&password=" + password);
+ }
+
+ protected void Button2_Click1(object sender, EventArgs e)
+ {
+ string Name = name.Text;
+ string Password = password.Text;
+
+ Response.Redirect($"WebForm1.aspx?Name={name}&Password={password}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..bcc2b7ae39767f7b7f062e8a896cb42228f7aa85
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// name 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox name;
+
+ ///
+ /// password 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox password;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..ce8759767e8aa0d21b0db1650ee7fb6c80a0e1c3
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..860ee7c31b20ef2fe60a0092ada20a083e41c785
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx.cs"
@@ -0,0 +1,35 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (!IsPostBack)
+ {
+ Response.Write("
登录成功!
");
+
+ Response.Write("GET");
+ string nameform = Request.QueryString["Name"];
+ string passwordform = Request.QueryString["Password"];
+
+ Response.Write("欢迎你," + nameform + ",你的密码是:" + passwordform);
+
+ Response.Write("POST");
+ string nameParams = Request.Params["name"];
+ string passwordParams = Request.Params["password"];
+
+ Response.Write("欢迎你," + nameParams + ",你的密码是:" + passwordParams);
+
+ }
+
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..52a837c60648ba1b53ccbc830a5a6ef2a4b20f5a
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/.keep" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..4125fe642bc3d5a8219565dda1f6247f6831c58e
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx"
@@ -0,0 +1,28 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication3.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..b01f516760f25b8630d9b29c5fe5d08f7db58891
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx.cs"
@@ -0,0 +1,26 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string userName = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ //get方式发送请求,就是把参数放在url里
+ //请求转发
+ Response.Redirect($"WebForm2.aspx?userName={TextBox1.Text}&pwd={TextBox2.Text}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..2ca4bb2e02733fed52e9f3168788d250715a8eb5
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication3.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..1ccabd594301e42b1eb3b1c2ced1a84fbe04dcbf
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx.cs"
@@ -0,0 +1,51 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string name = Request.Form["TextBox1"];
+ string pass = Request.Form["TextBox2"];
+
+ string name1 = Request.Params["TextBox1"];
+ string pass1 = Request.Params["TextBox2"];
+
+ string name3 = "";
+ string pass3 = "";
+ if (PreviousPage != null)
+ {
+ TextBox name2 = (TextBox)PreviousPage.FindControl("TextBox1");
+ TextBox pass2 = (TextBox)PreviousPage.FindControl("TextBox2");
+ if (name2 != null)
+ {
+ name3 = name2.Text;
+ }
+ if (pass2 != null)
+ {
+ pass3 = pass2.Text;
+ }
+ }
+ string name4 = Request.QueryString["userName"];
+ string pass4 = Request.QueryString["pwd"];
+
+ Response.Write("Request.Form ==> " + name + "
");
+ Response.Write("Request.Form ==> " + pass + "
");
+
+ Response.Write("Request.Params ==> " + name1 + "
");
+ Response.Write("Request.Params ==> " + pass1 + "
");
+
+ Response.Write("Request.QueryString ==> " + name4 + "
");
+ Response.Write("Request.QueryString ==> " + pass4 + "
");
+
+ Response.Write("PreviousPage ==> " + name3 + "
");
+ Response.Write("PreviousPage ==> " + pass3 + "
");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..38b1d6ecfec42a655025ec6d99ffc48bec5ec1ee
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication7.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4234ba04e4d962b3e5de360e373942fd9455e870
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication7
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string username = UserName.Text;
+ string pasword = Password.Text;
+ Response.Redirect($"WebForm2.aspx?Username={username}&Paserod={pasword}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5c4391b562359312b29f49782f731da7327d9e70
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm2.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication7
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string username = Request.Form["UserName"];
+ string password = Request.Form["Password"];
+
+ string usernaem2 = Request.QueryString["Username"];
+ string password2 = Request.QueryString["Paserod"];
+
+ Response.Write($"登入成功 !
用户名:{username}
密码:{password}");
+ Response.Write($"登入成功 !
用户名:{usernaem2}
密码:{password2}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..2033d16786c96c8e9bb7ee6c0b26d6d4ba7ed7a5
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx"
@@ -0,0 +1,27 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication7.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c72232228df3cae49170b18aff78b549d9d44f1d
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx.cs"
@@ -0,0 +1,26 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication7
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+
+ }
+
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string Username =UserName.Text;
+ string password = Pwd.Text;
+ Response.Redirect("WebForm2.aspx?userName=" + UserName + "&pwd=" + Pwd);
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..a1468d1e6b68b5b07601c03d5883383e862faaa5
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication7.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..631368b73fe7a6d7e18d0693aece7293b3794276
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx.cs"
@@ -0,0 +1,59 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication7
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string userName = Request.Form["UserName"];
+ string pwd = Request.Form["Pwd"];
+
+ string userName1 = Request.Params["UserName"];
+ string pwd1 = Request.Params["Pwd"];
+
+ string userName2 = Request.QueryString["UserName"];
+ string pwd2 = Request.QueryString["Pwd"];
+
+ string userName3 = "";
+ string pwd3 = "";
+ if (PreviousPage != null)
+ {
+ TextBox userNameBox = (TextBox)PreviousPage.FindControl("UserName");
+ TextBox pwdNameBox = (TextBox)PreviousPage.FindControl("Pwd");
+ if (userName != null)
+ {
+ userName3 = userNameBox.Text;
+ }
+ if (pwdNameBox != null)
+ {
+ pwd3 = pwdNameBox.Text;
+ }
+ }
+
+ Response.Write("Request.Form ==> " + userName + "
");
+ Response.Write("Request.Form ==> " + pwd + "
");
+
+ Response.Write("Request.Params ==> " + userName1 + "
");
+ Response.Write("Request.Params ==> " + pwd1 + "
");
+
+ Response.Write("Request.QueryString ==> " + userName2 + "
");
+ Response.Write("Request.QueryString ==> " + pwd2 + "
");
+
+ Response.Write("PreviousPage ==> " + userName3 + "
");
+ Response.Write("PreviousPage ==> " + pwd3 + "
");
+
+ string nameQueryString = Request.QueryString["name"];
+ string ageQueryString = Request.QueryString["age"];
+
+ Response.Write("Request.QueryString['name'] ==> " + nameQueryString + "
");
+ Response.Write("Request.QueryString['age'] ==> " + ageQueryString + "
");
+ }
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..271088a41342d8aeff859fa6a9776159745eda13
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx"
@@ -0,0 +1,25 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+<%-- 写一个登录页面,有用户名和密码,点击登录,跳转到登录成功页面,
+登录成功页面显示“欢迎你,张三,你的密码是:123”(h1效果)
+登录按钮有两个,一个是Post请求,一个是Get请求。
+在登录成功页面,需判断请求的方式,如果是Post,请用Post对应的方式获取Request数据,如果是Get,请用Get对应的方式获取Request数据。--%>
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..600134b31e213def177a40cfa5aef57fff33a1bd
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.cs"
@@ -0,0 +1,25 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string username = Username.Text;
+ string pwd = Pwd.Text;
+
+ Response.Redirect($"WebForm1.aspx?username{Username}&pwd{Pwd}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..1081e8d7f59e3eed6880bd6856fee13afb9b2d4e
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Username 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox Username;
+
+ ///
+ /// Pwd 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox Pwd;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..cb5c820eba5b1da27f6cd32bcab043f2d8ef4e3c
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..736af37330d1dc9a2c267fd99d01194af02e4146
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.cs"
@@ -0,0 +1,31 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+
+
+ string Username1 = Request.QueryString["Username"];
+ string Pwd1 = Request.QueryString["Pwd"];
+ Response.Write($"Post
欢迎你,{Username1},你的密码为{Pwd1}
");
+
+ string Username2 = Request.Params["username"];
+ string Pwd2 = Request.Params["pwd"];
+ Response.Write($"Post
欢迎你,{Username2},你的密码为{Pwd2}
");
+
+
+
+
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..249cc1aabbe6005fd5ab749a0ff8d517f3113a28
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..e25b80df6b1b8418f1049563e5200d5b858d7ec2
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx"
@@ -0,0 +1,31 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication3.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..e236f55c08d498b9f9800f9ce3beafd011739f1e
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.cs"
@@ -0,0 +1,39 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+
+ protected void CustomValidator1_ServerValidate(object source, ServerValidateEventArgs args)
+ {
+ if (args.Value == "admin")
+ {
+ args.IsValid = false;
+ }
+ else
+ {
+ args.IsValid = true;
+ }
+ }
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string text2 = TextBox2.Text;
+
+ Response.Redirect($"WebForm2.aspx?a={text}&b={text2}");
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..d2d5c2128df3ef379f42f39acdf0c143017750cb
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.designer.cs"
@@ -0,0 +1,114 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication3 {
+
+
+ public partial class WebForm1 {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// CustomValidator1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.CustomValidator CustomValidator1;
+
+ ///
+ /// RequiredFieldValidator1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.RequiredFieldValidator RequiredFieldValidator1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// RequiredFieldValidator2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.RequiredFieldValidator RequiredFieldValidator2;
+
+ ///
+ /// TextBox3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox3;
+
+ ///
+ /// RequiredFieldValidator3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.RequiredFieldValidator RequiredFieldValidator3;
+
+ ///
+ /// CompareValidator1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.CompareValidator CompareValidator1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..6240d1e7d9ddfbce593ec173eb1d73cf2eda96b9
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication3.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..bfd3721147842edd3f24ccc6a46f238665d3fcb6
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx.cs"
@@ -0,0 +1,26 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string name = Request.Form["TextBox1"];
+ string password = Request.Form["TextBox2"];
+
+ Response.Write($"Post :
欢迎你,{name},你的密码为{password}
");
+
+
+ string name2 = Request.QueryString["text"];
+ string password2 = Request.QueryString["text2"];
+ Response.Write($"Get :
欢迎你,{name2},你的密码为{password2}
");
+ }
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..cc2d0a4ddbe3109c9db1056291efbf8a21d9d32f
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+//
+// 此代码由工具生成。
+//
+// 对此文件的更改可能会导致不正确的行为,并且如果
+// 重新生成代码,这些更改将会丢失。
+//
+//------------------------------------------------------------------------------
+
+namespace WebApplication3
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/.keep" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..03ecd7f9723fed354adf86a99354214f31baed2c
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm1.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..319d454c00899a630badcea1fc028259e6d97e89
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm1.aspx.cs"
@@ -0,0 +1,32 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ //string nameget = TextBox1.Text;
+ //string passwordget = TextBox2.Text;
+ ////get方式发送请求,就是把参数放在url里
+ ////请求转发
+ //Response.Redirect($"WebForm2.aspx?TextBox1={nameget}&TextBox2={passwordget}");
+ string userName = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ //get方式发送请求,就是把参数放在url里
+ //请求转发
+ Response.Redirect($"WebForm2.aspx?userName={TextBox1}&pwd={TextBox2}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..ed8ed4b66e39ec893e9601d05b1a5965e2f36e39
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm2.aspx"
@@ -0,0 +1,17 @@
+<%--<%@ Reference Page="~/WebForm1.aspx" %>--%>
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..87520a5c437018883623affe91c3fd41a996da40
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/Request\343\200\201Response/WebForm2.aspx.cs"
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if(PreviousPage != null)
+ {
+ string namepost = Request.Form["Textbox1"];
+ string passwordpost = Request.Form["Textbox2"];
+ Response.Write($"你的用户名post:{namepost} 密码post:{passwordpost}");
+ }
+ else
+ {
+ string nameget = Request.QueryString["Textbox1"];
+ string passwordget = Request.QueryString["Textbox2"];
+ Response.Write($"你的用户名get:{nameget} 密码get:{passwordget}");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..21b8fe770db41ac5eaa42dacac3e24835fd405ad
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx"
@@ -0,0 +1,27 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+<%-- 写一个登录页面,有用户名和密码,点击登录,跳转到登录成功页面,
+登录成功页面显示“欢迎你,张三,你的密码是:123”(h1效果)
+
+登录按钮有两个,一个是Post请求,一个是Get请求。
+在登录成功页面,需判断请求的方式,
+如果是Post,请用Post对应的方式获取Request数据,如果是Get,请用Get对应的方式获取Request数据--%>。
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..6aa065d679053c6eb91e2dff66b4200281428b69
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx.cs"
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..3aa287535c7776b69c72e664ac12c132615d3049
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..a9da7f55ccde6235101ddd80d441cb170b6a0177
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx.cs"
@@ -0,0 +1,44 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ //string Username = Request.Form["username"];
+ //string Password = Request.Form["password"];
+ //Response.Write($"
欢迎你,{Username},你的密码是:{Password}");
+
+ string Username1 = Request.Params["username"];
+ string Password1 = Request.Params["password"];
+ Response.Write($"
欢迎你,{Username1},你的密码是:{Password1}");//Get
+
+ string Username2 = Request.QueryString[""];//填url路径名
+ string Password2 = Request.QueryString[""];//填url路径名
+ Response.Write($"
欢迎你,{Username2},你的密码是:{Password2}");//Post
+
+ Response.Redirect("");
+ //if (PreviousPage != null)
+ //{
+ // string Username3 = "";
+ // string Password3 = "";
+ // TextBox namebox = (TextBox)PreviousPage.FindControl("username");
+ // TextBox passwordbox = (TextBox)PreviousPage.FindControl("password");
+ // if (Username3 != null)
+ // {
+ // Response.Write("Username3.Text");
+ // }
+ // else if (Password3 != null)
+ // {
+ // Response.Write("Password3.Text");
+ // }
+ //}
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..9fe9928bfb0c6b2c154e896d5367c53d9eeffc1e
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx"
@@ -0,0 +1,21 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..623571bdf6a15eddd185ac9ff42f48b72ed0632c
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.cs"
@@ -0,0 +1,25 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string username = Username.Text;
+ string password = Password.Text;
+
+ Response.Redirect($"WebForm2.aspx?username={Username.Text}&password={Password.Text}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..6cd522cda226112390ac59b8675668f59a2269a0
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Username 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox Username;
+
+ ///
+ /// Password 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox Password;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..ce8759767e8aa0d21b0db1650ee7fb6c80a0e1c3
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f07b42f94c4847e3439ca90b81f06f03903cd214
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.cs"
@@ -0,0 +1,46 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string username = Request.Form["Username"];
+ string password = Request.Form["Password"];
+
+ string username1 = Request.Params["Username"];
+ string password1 = Request.Params["Password"];
+
+ string username2 = Request.QueryString["Username"];
+ string password2 = Request.QueryString["Password"];
+
+ string username3 = "";
+ string password3 = "";
+ if (PreviousPage != null)
+ {
+ TextBox userNameBox = (TextBox)PreviousPage.FindControl("Username");
+ TextBox pwdNameBox = (TextBox)PreviousPage.FindControl("Password");
+ if (userNameBox != null)
+ {
+ username3 = userNameBox.Text;
+ }
+ if (pwdNameBox != null)
+ {
+ password3 = pwdNameBox.Text;
+ }
+ }
+
+
+ Response.Write("Form==>" + $"
登录成功,欢迎{username},您的密码是{password}
");
+ Response.Write("Params==>" + $"
登录成功,欢迎{username1},您的密码是{password1}
");
+ Response.Write("QueryString==>" + $"
登录成功,欢迎{username2},您的密码是{password2}
");
+ Response.Write("PreviousPage==>" + $"
登录成功,欢迎{username3},您的密码是{password3}
");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.designer.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..52a837c60648ba1b53ccbc830a5a6ef2a4b20f5a
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/.keep" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..38b1d6ecfec42a655025ec6d99ffc48bec5ec1ee
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication7.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4234ba04e4d962b3e5de360e373942fd9455e870
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication7
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string username = UserName.Text;
+ string pasword = Password.Text;
+ Response.Redirect($"WebForm2.aspx?Username={username}&Paserod={pasword}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5c4391b562359312b29f49782f731da7327d9e70
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication7
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string username = Request.Form["UserName"];
+ string password = Request.Form["Password"];
+
+ string usernaem2 = Request.QueryString["Username"];
+ string password2 = Request.QueryString["Paserod"];
+
+ Response.Write($"登入成功 !
用户名:{username}
密码:{password}");
+ Response.Write($"登入成功 !
用户名:{usernaem2}
密码:{password2}");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/.keep" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..12679deb188743cbc4c33eaaa89f6e8814f4ba49
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx"
@@ -0,0 +1,31 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..550527d0e85bc1c7fe2738fc9eceed478b808153
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx.cs"
@@ -0,0 +1,37 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ Label1.Text = "点击
跳转 ";
+ }
+
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string a = name.Text;
+ string b = pawss.Text;
+ Response.Redirect($"WebForm2.aspx?a={name}&b={pawss}");
+ }
+
+ protected void Button2_Click1(object sender, EventArgs e)
+ {
+ string usename1 = Request.Params["name"];
+ string pawss1 = Request.Params["pawss"];
+ Response.Write("post欢迎您" + usename1 + "你的密码是" + pawss1 + "");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..9c38ffd7ab2525ef533b0740f2a94901159939a2
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx"
@@ -0,0 +1,18 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx.cs" "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..ab5baae61b2f180f221bcd9f2510f4b81c3a49e1
--- /dev/null
+++ "b/\347\254\2544\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx.cs"
@@ -0,0 +1,40 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+
+ string usename = Request.Params["name"];
+ string pawss = Request.Params["pawss"];
+ Response.Write("
"+"登陆成功 姓名:" +usename);
+ Response.Write("登陆成功 密码:" + pawss + "");
+
+
+
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ string usename1 = Request.Form["name"];
+ string pawss1 = Request.Form["pawss"];
+ Response.Write("post欢迎您" + usename1 + "你的密码是" + pawss1);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string userName2 = Request.QueryString["name"];
+ string pwd2 = Request.QueryString["pawss"];
+ Response.Write("get欢迎您 " + userName2 + "你的密码是 " + pwd2);
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/.keep" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..77f9decabf465d7cbb9c4f56979692b3a1974c58
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx"
@@ -0,0 +1,18 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..d11d86faa74a0feb51854a28ce1bb19bead7d07a
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx.cs"
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7c825094a9de1489e34a639c8ed45a5acb5b96e9
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..b1b19286739bc18ce4b58ea9308431307dcea68d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm2.aspx.cs"
@@ -0,0 +1,45 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"]==null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ string charString = TextBox1.Text;
+ Literal literal = new Literal();
+ literal.Text = name + " " + time + " " + charString + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..699f3641f9c5a37799bd66122af30951e7a1b401
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx"
@@ -0,0 +1,18 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..e9d873ad1d10a574ba4e963e016d3b0bb9a81445
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx.cs"
@@ -0,0 +1,29 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = UserName.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+
+
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..22a193743efe358f94a0f7216fbfa07b7b74678d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm2.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..b9d379a21f423703fc934e37be35ee0368170f49
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm2.aspx.cs"
@@ -0,0 +1,45 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }else if(Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ string chatString = TextBox1.Text;
+ Literal literal = new Literal();
+ literal.Text = name + " " + time + " :" + chatString + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..35146e8b02b49c1e9b3b09afd913944532b2253c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication8.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..300643ab05c8709a6c6a8d5068e2466383482d0c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx.cs"
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication8
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..0a93192612b9b74b6a10f4efe2acab7078da9c45
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx"
@@ -0,0 +1,25 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication8.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..084b085721bcb979176dff3612f33efacaedd700
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx.cs"
@@ -0,0 +1,49 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication8
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }else if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ string charString = TextBox1.Text;
+ Literal literal = new Literal();
+ literal.Text = name + " " + time + ":" + charString + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+};
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..d2a18b8eb3c5268ca1377d703aaf7d1cb5df9cf2
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4ef8bd5baf3c6ca6f7cc295f8d59b5d95b7c62e5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx.cs"
@@ -0,0 +1,30 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name) )
+ {
+ Session["useName"]= name;
+
+ Response.Redirect("WebForm2.aspx");
+
+ return;
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..32dfd7293273e8646f71f9224c3b9c6ccfa0864d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm2.aspx"
@@ -0,0 +1,32 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..91c86b6095154def186a9e4c939a6f2502a12a5e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["useName"]==null)
+ {
+
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["useName"].ToString();
+ string time = DateTime.Now.ToShortTimeString();
+ string speak = TextBox1.Text;
+
+ Literal literal = new Literal();
+
+
+
+ literal.Text = name + " " + time + " :" + speak + "
";
+
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..d2a18b8eb3c5268ca1377d703aaf7d1cb5df9cf2
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4ef8bd5baf3c6ca6f7cc295f8d59b5d95b7c62e5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm1.aspx.cs"
@@ -0,0 +1,30 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name) )
+ {
+ Session["useName"]= name;
+
+ Response.Redirect("WebForm2.aspx");
+
+ return;
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..32dfd7293273e8646f71f9224c3b9c6ccfa0864d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm2.aspx"
@@ -0,0 +1,32 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..91c86b6095154def186a9e4c939a6f2502a12a5e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["useName"]==null)
+ {
+
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["useName"].ToString();
+ string time = DateTime.Now.ToShortTimeString();
+ string speak = TextBox1.Text;
+
+ Literal literal = new Literal();
+
+
+
+ literal.Text = name + " " + time + " :" + speak + "
";
+
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..d2a18b8eb3c5268ca1377d703aaf7d1cb5df9cf2
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4ef8bd5baf3c6ca6f7cc295f8d59b5d95b7c62e5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm1.aspx.cs"
@@ -0,0 +1,30 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name) )
+ {
+ Session["useName"]= name;
+
+ Response.Redirect("WebForm2.aspx");
+
+ return;
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..32dfd7293273e8646f71f9224c3b9c6ccfa0864d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm2.aspx"
@@ -0,0 +1,32 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..91c86b6095154def186a9e4c939a6f2502a12a5e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\210\230\351\207\221\346\265\267/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["useName"]==null)
+ {
+
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["useName"].ToString();
+ string time = DateTime.Now.ToShortTimeString();
+ string speak = TextBox1.Text;
+
+ Literal literal = new Literal();
+
+
+
+ literal.Text = name + " " + time + " :" + speak + "
";
+
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..da1fb840eaef7f0f9d978ea1a4531b16025d3839
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx"
@@ -0,0 +1,18 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..fd762a3d4d6f332f4ea7adafb6ca9ade3c0fc42b
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx.cs"
@@ -0,0 +1,26 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = "name";
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..6e5430bca26c81df2763cd00b258d15bc731358d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4cc386fc389f65bf7c62955753450e893b5b8a16
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm2.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ Literal literal = new Literal();
+ literal.Text = name + " " + time +" " + text +"
" ;
+
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7aff0c97aad159d19fb5956a18846a9122694d69
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2ab3b886a6fe161ad8256b2f2981202f19f1e29c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..634710d9fc9058c72818675a23c03b31129e7282
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..60d66841507f70e74536d2ab75430e6ddac456a4
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm2.aspx.cs"
@@ -0,0 +1,50 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else
+ {
+ if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string name = Session["name"].ToString();
+ string nowTime = DateTime.Now.ToString();
+
+ Literal literal = new Literal();
+ literal.Text = name + " " + nowTime + " " + ":" + text + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/.keep" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..75f15c3fc9e00c6ea8ee4017bb4c76654613afad
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2fcd617f2f0480cc0ac7e1a62d10c9fc8a5a1f9c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm1.aspx.cs"
@@ -0,0 +1,34 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+
+ if (TextBox1.Text != null)
+ {
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5b1232902355f3eaf6cd0e7cc1ad57eccf0dfb35
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..864157c10809ac7a85d5fb359d8b0c02a2436121
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..911aa61cf220d6dbc9d148fff53bfbad177a4f05
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["ChatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ Panel1.Controls.Add((Panel)Application["ChatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = (string)Session["name"];
+ string text = TextBox1.Text;
+ string time = DateTime.Now.ToString();
+
+
+ Literal literal1 = new Literal();
+
+ literal1.Text = time + " " + name + ":" + "
" + text + "
" + "
";
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal1);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..63042fb7ff55d54840839abe405c21001dcf9e03
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/WebForm2.aspx.designer.cs"
@@ -0,0 +1,89 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// Panel2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel2;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..6c7848b8aba209ea9d07a0b1b91683c2a1ec49d5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2ab3b886a6fe161ad8256b2f2981202f19f1e29c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5b1232902355f3eaf6cd0e7cc1ad57eccf0dfb35
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..fdb9b8134c748b0865689eb812f4f47c1d072991
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..010ae21b0ef4233eff1605cea40e54916825ff1f
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx.cs"
@@ -0,0 +1,49 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string name = Session["name"].ToString();
+ string time = DateTime.Now.ToString();
+
+ Literal literal = new Literal();
+ literal.Text = name + " : " + text + " " + time + " ";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..943864e324162004f727b312f04b7840a2b70364
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx.designer.cs"
@@ -0,0 +1,80 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// Panel2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel2;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..2ce3e0aa39afe2078457dbc5f2b4c4cecb9273f4
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f247e0e0c3453e8c69f0467ffb5a8d9106421956
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm1.aspx.cs"
@@ -0,0 +1,30 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["useName"] = name;
+
+ Response.Redirect("WebForm2.aspx");
+
+ return;
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..dcba52d3affe9a4c1982db50ae24299e7dc6da27
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..8ec53e35c1c64c9da57d27714b0065525951342d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx.cs"
@@ -0,0 +1,51 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["ChatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ Panel1.Controls.Add((Panel)Application["ChatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = (string)Session["name"];
+ string text = TextBox1.Text;
+ string time = DateTime.Now.ToString();
+
+
+ Literal literal1 = new Literal();
+
+ literal1.Text = time + " " + name + ":" + "
" + text + "
" + "
";
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal1);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7aff0c97aad159d19fb5956a18846a9122694d69
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2ab3b886a6fe161ad8256b2f2981202f19f1e29c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..634710d9fc9058c72818675a23c03b31129e7282
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..60d66841507f70e74536d2ab75430e6ddac456a4
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm2.aspx.cs"
@@ -0,0 +1,50 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else
+ {
+ if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string name = Session["name"].ToString();
+ string nowTime = DateTime.Now.ToString();
+
+ Literal literal = new Literal();
+ literal.Text = name + " " + nowTime + " " + ":" + text + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..6c7848b8aba209ea9d07a0b1b91683c2a1ec49d5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2356e6b6772be35d589f0fcafb125e221bfc632a
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx.cs"
@@ -0,0 +1,27 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..149a161b20d0796a5a8708c1304927800853e591
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm2.aspx"
@@ -0,0 +1,28 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..ee1e6a42aebc4077dc5106f72f4e2b37d785fa68
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm2.aspx.cs"
@@ -0,0 +1,47 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ string str = TextBox1.Text;
+ Literal literal = new Literal();
+ literal.Text = name + " " + time + " " + str;
+ ((Panel)(Application["chatRoom"])).Controls.Add(literal);
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7aff0c97aad159d19fb5956a18846a9122694d69
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2ab3b886a6fe161ad8256b2f2981202f19f1e29c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..634710d9fc9058c72818675a23c03b31129e7282
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..60d66841507f70e74536d2ab75430e6ddac456a4
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm2.aspx.cs"
@@ -0,0 +1,50 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else
+ {
+ if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string name = Session["name"].ToString();
+ string nowTime = DateTime.Now.ToString();
+
+ Literal literal = new Literal();
+ literal.Text = name + " " + nowTime + " " + ":" + text + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..4eb83eb0f4117c937d84fcaee7a84ce3166e81a5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm1.aspx"
@@ -0,0 +1,21 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Login.aspx.cs" Inherits="Demo616.ChatDemo.Login" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..8e72ff7ee9eb8b2a1b19c15efc33dcaaa59abd58
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace Demo616.ChatDemo
+{
+ public partial class Login : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ Session.Add("username", TextBox1.Text);
+ Session.Add("password", TextBox2.Text);
+ Response.Redirect("ChatRoom.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..c7b4eea058be9b35d28155c3e6973451cc6abd92
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm2.aspx"
@@ -0,0 +1,26 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ChatRoom.aspx.cs" Inherits="Demo616.ChatDemo.ChatRoom" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..e77186038b3ba1f554d4d249503a36ac6746f295
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm2.aspx.cs"
@@ -0,0 +1,54 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace Demo616.ChatDemo
+{
+ public partial class ChatRoom : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ //判断用户名密码是否为空
+ if (Session["username"]==null &&Session["password"]==null)
+ {
+ Response.Redirect("Login.aspx");
+ }
+ //判断应用变量是否为空
+ if (Application["chatRoom"] ==null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ //获取本页Panel控件 添加应用变量chatRoom
+ Panel1.Controls.Add((Control)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ //获取 姓名,文本内容,当前时间
+ string Username = Session["username"].ToString();
+ string Text = TextBox1.Text;
+ string Time = DateTime.Now.ToString("t");
+
+ //创建label控件
+ Literal literal = new Literal();
+
+ //设置literal的内容为姓名 时间 文本
+ literal.Text = $"
{Username} {Time}
{Text}
";
+
+ //获取应用变量 强制转换成Panel类型
+ Panel p = (Panel)Application["chatRoom"];
+
+ //把创建好的literal添加到上一行获取的panel中
+ p.Controls.Add(literal);
+ }
+
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..75f15c3fc9e00c6ea8ee4017bb4c76654613afad
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2fcd617f2f0480cc0ac7e1a62d10c9fc8a5a1f9c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx.cs"
@@ -0,0 +1,34 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+
+ if (TextBox1.Text != null)
+ {
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5b1232902355f3eaf6cd0e7cc1ad57eccf0dfb35
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..864157c10809ac7a85d5fb359d8b0c02a2436121
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..911aa61cf220d6dbc9d148fff53bfbad177a4f05
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["ChatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ Panel1.Controls.Add((Panel)Application["ChatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = (string)Session["name"];
+ string text = TextBox1.Text;
+ string time = DateTime.Now.ToString();
+
+
+ Literal literal1 = new Literal();
+
+ literal1.Text = time + " " + name + ":" + "
" + text + "
" + "
";
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal1);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..63042fb7ff55d54840839abe405c21001dcf9e03
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm2.aspx.designer.cs"
@@ -0,0 +1,89 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// Panel2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel2;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm3.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm3.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..6c7848b8aba209ea9d07a0b1b91683c2a1ec49d5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm3.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm3.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm3.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..90c1bee730a565a6ca4d382384c10a6979eeaa42
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm3.aspx.cs"
@@ -0,0 +1,27 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm4.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm4.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..73a4da0d3f9f6a8928473e2532beb7a76ec1b4d2
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm4.aspx"
@@ -0,0 +1,28 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm4" %>
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm4.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm4.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..32c053e5307795050d6137cce50bfabdec7f97fe
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm4.aspx.cs"
@@ -0,0 +1,46 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm4 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ string str = TextBox1.Text;
+ Literal literal = new Literal();
+ literal.Text = name + " " + time + " " + str;
+ ((Panel)(Application["chatRoom"])).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..d2a18b8eb3c5268ca1377d703aaf7d1cb5df9cf2
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4ef8bd5baf3c6ca6f7cc295f8d59b5d95b7c62e5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm1.aspx.cs"
@@ -0,0 +1,30 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name) )
+ {
+ Session["useName"]= name;
+
+ Response.Redirect("WebForm2.aspx");
+
+ return;
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..32dfd7293273e8646f71f9224c3b9c6ccfa0864d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm2.aspx"
@@ -0,0 +1,32 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..91c86b6095154def186a9e4c939a6f2502a12a5e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["useName"]==null)
+ {
+
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["useName"].ToString();
+ string time = DateTime.Now.ToShortTimeString();
+ string speak = TextBox1.Text;
+
+ Literal literal = new Literal();
+
+
+
+ literal.Text = name + " " + time + " :" + speak + "
";
+
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..5d86422f241c2c0e822ab854024e2ee034bfd067
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication12.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f7669598e84c2e2baf65707e648af04b64113cb9
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx.cs"
@@ -0,0 +1,27 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication12
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..94732980810ccc99365f4a49eb9dab7a60a75f5e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication12
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..58b4581da1c03a81bbca86f62ebf8bf1cdce6398
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication12.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2dd9e9018de6e4c9ae04a5bcfeda93bec3e8ff3e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm2.aspx.cs"
@@ -0,0 +1,45 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication12
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }else if (Application["chatRoom"]==null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Page.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ string charString = TextBox1.Text;
+ Literal literal = new Literal();
+ literal.Text = name + " " + time + ":" + charString + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c0696b1353bd74847aba7155999e1698c7de5747
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm2.aspx.designer.cs"
@@ -0,0 +1,80 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication12
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// Panel2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel2;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/.keep" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..6f8725aada47d04efcf81f0c8c6f1b6ea6c3d334
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..16ea4b4f82d7c220f65a02cb71980da2a6f1b8c1
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.cs"
@@ -0,0 +1,34 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+
+ if (TextBox1.Text != null)
+ {
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..605053b6a79163601598412aa8976a0d0690db94
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..684ca1ecfa66d2915e55ce6898fcd2b678b6ff5b
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c3e4445177d1cb80d5ddd69d80a7d32cb8c75cc0
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["ChatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ Panel1.Controls.Add((Panel)Application["ChatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = (string)Session["name"];
+ string text = TextBox1.Text;
+ string time = DateTime.Now.ToString();
+
+
+ Literal literal1 = new Literal();
+
+ literal1.Text = time + " " + name + ":" + "
" + text + "
" + "
";
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal1);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..025b910d97bd21705eec54cf4898e24aa5d41968
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.designer.cs"
@@ -0,0 +1,89 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// Panel2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel2;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..d2a18b8eb3c5268ca1377d703aaf7d1cb5df9cf2
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4ef8bd5baf3c6ca6f7cc295f8d59b5d95b7c62e5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm1.aspx.cs"
@@ -0,0 +1,30 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name) )
+ {
+ Session["useName"]= name;
+
+ Response.Redirect("WebForm2.aspx");
+
+ return;
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..32dfd7293273e8646f71f9224c3b9c6ccfa0864d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm2.aspx"
@@ -0,0 +1,32 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..91c86b6095154def186a9e4c939a6f2502a12a5e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\242\201\345\220\257\351\221\253/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["useName"]==null)
+ {
+
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["useName"].ToString();
+ string time = DateTime.Now.ToShortTimeString();
+ string speak = TextBox1.Text;
+
+ Literal literal = new Literal();
+
+
+
+ literal.Text = name + " " + time + " :" + speak + "
";
+
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..e46359ec2e3e013bccfddddac00f935d509c871f
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx"
@@ -0,0 +1,18 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..86c4cccee39a67f363360c6eba1f49fcc061742f
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.cs"
@@ -0,0 +1,41 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ //string name = TextBox1.Text;
+
+ //if (!string.IsNullOrWhiteSpace(name))
+
+ //{
+
+ // Session["UserName"] = name;
+
+ // Response.Redirect("WebForm2.aspx");
+
+ //}
+
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void TextBox1_TextChanged(object sender, EventArgs e)
+ {
+ string name = Button1.Text;
+ Session["name"] = name;
+ Response.Redirect("webform2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5b1232902355f3eaf6cd0e7cc1ad57eccf0dfb35
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..b8f3021ea0478006f24a8af409138ff7da2c6415
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f3187aac15fb7bf24a45d6a2d6ec7530752d3d1d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.cs"
@@ -0,0 +1,50 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["speak"] == null)
+ {
+ Application["speak"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["speak"]);
+ }
+ else {
+ Response.Redirect("webform1.aspx");
+ }
+ }
+
+
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string a = TextBox1.Text;
+ string name = Session["name"].ToString();
+ string b = DateTime.Now.ToString();
+ Literal li = new Literal();
+ li.Text = name + " " + b + ":" + a + "< br />";
+ ((Panel)Application["speak"]).Controls.Add(li);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender,e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..ed89e4a81f3dd30fd53f993b414038f55f8b129e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/WebForm2.aspx.designer.cs"
@@ -0,0 +1,71 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..75f15c3fc9e00c6ea8ee4017bb4c76654613afad
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2fcd617f2f0480cc0ac7e1a62d10c9fc8a5a1f9c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.cs"
@@ -0,0 +1,34 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+
+ if (TextBox1.Text != null)
+ {
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5b1232902355f3eaf6cd0e7cc1ad57eccf0dfb35
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..864157c10809ac7a85d5fb359d8b0c02a2436121
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..911aa61cf220d6dbc9d148fff53bfbad177a4f05
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["ChatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ Panel1.Controls.Add((Panel)Application["ChatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = (string)Session["name"];
+ string text = TextBox1.Text;
+ string time = DateTime.Now.ToString();
+
+
+ Literal literal1 = new Literal();
+
+ literal1.Text = time + " " + name + ":" + "
" + text + "
" + "
";
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal1);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..63042fb7ff55d54840839abe405c21001dcf9e03
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm2.aspx.designer.cs"
@@ -0,0 +1,89 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// Panel2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel2;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7aff0c97aad159d19fb5956a18846a9122694d69
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2ab3b886a6fe161ad8256b2f2981202f19f1e29c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..634710d9fc9058c72818675a23c03b31129e7282
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..60d66841507f70e74536d2ab75430e6ddac456a4
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx.cs"
@@ -0,0 +1,50 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else
+ {
+ if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string name = Session["name"].ToString();
+ string nowTime = DateTime.Now.ToString();
+
+ Literal literal = new Literal();
+ literal.Text = name + " " + nowTime + " " + ":" + text + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..d2a18b8eb3c5268ca1377d703aaf7d1cb5df9cf2
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4ef8bd5baf3c6ca6f7cc295f8d59b5d95b7c62e5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm1.aspx.cs"
@@ -0,0 +1,30 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name) )
+ {
+ Session["useName"]= name;
+
+ Response.Redirect("WebForm2.aspx");
+
+ return;
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..32dfd7293273e8646f71f9224c3b9c6ccfa0864d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx"
@@ -0,0 +1,32 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..91c86b6095154def186a9e4c939a6f2502a12a5e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\347\275\227\346\265\252\345\255\220/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["useName"]==null)
+ {
+
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["useName"].ToString();
+ string time = DateTime.Now.ToShortTimeString();
+ string speak = TextBox1.Text;
+
+ Literal literal = new Literal();
+
+
+
+ literal.Text = name + " " + time + " :" + speak + "
";
+
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/.keep" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..47f0334c319a244da53cea9d66afd396463395e1
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx"
@@ -0,0 +1,18 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..8210bac6e78126de0cb1551f6f24011f45e1c625
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx.cs"
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..24ea47c9766c90e32eaaa1098904825c281ce09f
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..ebf0945fe1c20923156d53930595c75ed2de833b
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm2.aspx.cs"
@@ -0,0 +1,45 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"]==null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ string charString = TextBox1.Text;
+ Literal literal = new Literal();
+ literal.Text = name + " " + time + " " + charString + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/.keep" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..75f15c3fc9e00c6ea8ee4017bb4c76654613afad
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2fcd617f2f0480cc0ac7e1a62d10c9fc8a5a1f9c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx.cs"
@@ -0,0 +1,34 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+
+ if (TextBox1.Text != null)
+ {
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..864157c10809ac7a85d5fb359d8b0c02a2436121
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..911aa61cf220d6dbc9d148fff53bfbad177a4f05
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["ChatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ Panel1.Controls.Add((Panel)Application["ChatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = (string)Session["name"];
+ string text = TextBox1.Text;
+ string time = DateTime.Now.ToString();
+
+
+ Literal literal1 = new Literal();
+
+ literal1.Text = time + " " + name + ":" + "
" + text + "
" + "
";
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal1);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..da1fb840eaef7f0f9d978ea1a4531b16025d3839
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx"
@@ -0,0 +1,18 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..fd762a3d4d6f332f4ea7adafb6ca9ade3c0fc42b
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx.cs"
@@ -0,0 +1,26 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = "name";
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..6e5430bca26c81df2763cd00b258d15bc731358d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4cc386fc389f65bf7c62955753450e893b5b8a16
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm2.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ Literal literal = new Literal();
+ literal.Text = name + " " + time +" " + text +"
" ;
+
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..b51e53d20bb74bcdd9dbe290c30c37fed106fe50
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..014ed934564532e503ba3367eb11785dc0ac5c8c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.cs"
@@ -0,0 +1,27 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name) )
+ {
+ Session["username"] = name;
+ Response.Redirect("WebFrom2.aspx");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5b1232902355f3eaf6cd0e7cc1ad57eccf0dfb35
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..afdb7a6f4d482443fe5f05f0958836945e40bae0
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..add08c13b9c19ccac70a810614827e98458a9218
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.cs"
@@ -0,0 +1,53 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["username"] != null)
+ {
+ if (Application["chatromm"] == null)
+ {
+ Application["chatroom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatroom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string username = Session["username"].ToString();
+ string time = DateTime.Now.ToString();
+
+ Literal literal = new Literal();
+ literal.Text = username + "" + time + " :" + text + "
";
+ ((Panel)Application["charroom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..943864e324162004f727b312f04b7840a2b70364
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm2.aspx.designer.cs"
@@ -0,0 +1,80 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// Panel2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel2;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..d2a18b8eb3c5268ca1377d703aaf7d1cb5df9cf2
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..4ef8bd5baf3c6ca6f7cc295f8d59b5d95b7c62e5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.cs"
@@ -0,0 +1,30 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name) )
+ {
+ Session["useName"]= name;
+
+ Response.Redirect("WebForm2.aspx");
+
+ return;
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..32dfd7293273e8646f71f9224c3b9c6ccfa0864d
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx"
@@ -0,0 +1,32 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..91c86b6095154def186a9e4c939a6f2502a12a5e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["useName"]==null)
+ {
+
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["useName"].ToString();
+ string time = DateTime.Now.ToShortTimeString();
+ string speak = TextBox1.Text;
+
+ Literal literal = new Literal();
+
+
+
+ literal.Text = name + " " + time + " :" + speak + "
";
+
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..c12bbcbdf2ddb4fb6d302468de14659f4d78f66e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5bbe3183e12cf0b82888eabe369a8db871428f46
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx.cs"
@@ -0,0 +1,46 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"]==null)
+ {
+ Response.Redirect("WebForm2.aspx");
+ }
+ else if(Application["CharRoom"] == null)
+ {
+ Application["CharRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["CharRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ string Char = TextBox1.Text;
+ Literal literal = new Literal();
+ literal.Text = name + " " + time + " " + Char+"
";
+ ((Panel)(Application["CharRoom"])).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..602e80b7b5d8f498113c89fb8e4006df35f369ff
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm2.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..12a281547355881bbf715030480649460498a703
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm2.aspx.cs"
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = name;
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..ef91308d06c1cca3df85260b7f8e0dc0ed6c28ad
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication3.Speaking.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..52c69130569d984cf0d5f2af3249086c36caad10
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm1.aspx.cs"
@@ -0,0 +1,29 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3.Speaking
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Username_TextChanged(object sender, EventArgs e)
+ {
+ string name = Username.Text;//用户姓名接收
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..b62bcd7e1bb5b1526a3c395f477da0b816f2becc
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication3.Speaking.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..b7c015099404c546dcbb33c422e3abfb8e5771e3
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/WebForm2.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3.Speaking
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["Speakroom"] == null)
+ {
+ Application["Speakroom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["Speakroom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");//回到登陆界面
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)//发送
+ {
+ string text = TextBox1.Text;
+ string name = Session["name"].ToString();
+ string nowtime = DateTime.Now.ToString();
+
+ Literal literal = new Literal();
+ literal.Text = name + " " + nowtime + " :" + text + "
";
+ ((Panel)Application["Speakroom"]).Controls.Add(literal);
+ }
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("Webform1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..6c7848b8aba209ea9d07a0b1b91683c2a1ec49d5
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2ab3b886a6fe161ad8256b2f2981202f19f1e29c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5b1232902355f3eaf6cd0e7cc1ad57eccf0dfb35
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..4fe6f9468d651b3e50fc14d6765dc036febf2315
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..010ae21b0ef4233eff1605cea40e54916825ff1f
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.cs"
@@ -0,0 +1,49 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string name = Session["name"].ToString();
+ string time = DateTime.Now.ToString();
+
+ Literal literal = new Literal();
+ literal.Text = name + " : " + text + " " + time + " ";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..943864e324162004f727b312f04b7840a2b70364
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm2.aspx.designer.cs"
@@ -0,0 +1,80 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// Panel2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel2;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..75f15c3fc9e00c6ea8ee4017bb4c76654613afad
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2fcd617f2f0480cc0ac7e1a62d10c9fc8a5a1f9c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.cs"
@@ -0,0 +1,34 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+
+ if (TextBox1.Text != null)
+ {
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..5b1232902355f3eaf6cd0e7cc1ad57eccf0dfb35
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.designer.cs"
@@ -0,0 +1,44 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..864157c10809ac7a85d5fb359d8b0c02a2436121
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..911aa61cf220d6dbc9d148fff53bfbad177a4f05
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["ChatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ Panel1.Controls.Add((Panel)Application["ChatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = (string)Session["name"];
+ string text = TextBox1.Text;
+ string time = DateTime.Now.ToString();
+
+
+ Literal literal1 = new Literal();
+
+ literal1.Text = time + " " + name + ":" + "
" + text + "
" + "
";
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal1);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.designer.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..63042fb7ff55d54840839abe405c21001dcf9e03
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.designer.cs"
@@ -0,0 +1,89 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel1;
+
+ ///
+ /// Panel2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Panel Panel2;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Button2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button2;
+
+ ///
+ /// Button3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button3;
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/.keep" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7aff0c97aad159d19fb5956a18846a9122694d69
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2ab3b886a6fe161ad8256b2f2981202f19f1e29c
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..634710d9fc9058c72818675a23c03b31129e7282
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm2.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..60d66841507f70e74536d2ab75430e6ddac456a4
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\345\244\251\347\277\224/WebForm2.aspx.cs"
@@ -0,0 +1,50 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else
+ {
+ if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string text = TextBox1.Text;
+ string name = Session["name"].ToString();
+ string nowTime = DateTime.Now.ToString();
+
+ Literal literal = new Literal();
+ literal.Text = name + " " + nowTime + " " + ":" + text + "
";
+ ((Panel)Application["chatRoom"]).Controls.Add(literal);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Judgment.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Judgment.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..182875c08e13b27cc0c103d36f8bf178865f97fd
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Judgment.cs"
@@ -0,0 +1,58 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ConsoleApp14
+{
+ class Judgment
+ {
+ int sum1 = 0;
+ int sum2 = 0;
+ int sum3 = 0;
+ int sum4 = 0;
+
+ public void Date(int p1, int p2)
+ {
+ if (p1 - p2 == -2 || p1 - p2 == 1)
+ {
+ Console.WriteLine("玩家胜利!");
+ sum2++;
+ }
+ else if (p1 == p2)
+ {
+ Console.WriteLine("平局");
+ sum3++;
+ }
+ else
+ {
+ Console.WriteLine("玩家失败!");
+ sum4++;
+ }
+ sum1 = sum2 + sum3 + sum4;
+
+ }
+
+
+ internal void Date1()
+ {
+ Console.WriteLine("你的胜场数:{0}", sum2);
+ Console.WriteLine("对手胜场数:{0}", sum4);
+ Console.WriteLine("平局场数:{0}", sum3);
+ Console.WriteLine("总场数:{0}", sum1);
+ if (sum2 > sum4)
+ {
+ Console.WriteLine("你赢了");
+ }
+ else if (sum2 < sum4)
+ {
+ Console.WriteLine("你输了");
+ }
+ else if (sum2 == sum4)
+ {
+ Console.WriteLine("平局");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Me.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Me.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..292a2d93fa594de24f5313524a97d90200ab5709
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Me.cs"
@@ -0,0 +1,40 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ConsoleApp14
+{
+ class Ad
+ {
+ private string name;
+
+ public Ad(string name)
+ {
+ this.name = name;
+ }
+
+ public string Name { get => name; set => name = value; }
+
+ public int Test1()
+ {
+ Console.WriteLine("请你选择出拳:1.剪刀 2.石头 3.布");
+ int k = int.Parse(Console.ReadLine());
+ switch (a)
+ {
+ case 1:
+ Console.WriteLine("{0}出了一个剪刀",name);
+ break;
+ case 2:
+ Console.WriteLine("{0}出了一个石头", name);
+ break;
+ case 3:
+ Console.WriteLine("{0}出了一个布",name);
+ break;
+ }
+
+ return k;
+ }
+ }
+}
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Npc.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Npc.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..db37cc4f9feb61154c97a26210c3396067bb2a54
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Npc.cs"
@@ -0,0 +1,42 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ConsoleApp14
+{
+ class Npc : Me
+ {
+ private string name1;
+
+ public Npc(string name, string name1) : base(name)
+ {
+ this.Name1 = name1;
+
+ }
+
+ public string Name1 { get => name1; set => name1 = value; }
+
+ public int MDF1()
+ {
+ Random random = new Random();
+ int result = random.Next(1, 4);
+ string str = Convert.ToString(result);
+ switch (result)
+ {
+ case 1:
+ str = "剪刀";
+ break;
+ case 2:
+ str = "石头";
+ break;
+ case 3:
+ str = "布";
+ break;
+ }
+ Console.WriteLine("{0}出了一个{1}",name1,str);
+ return result;
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Program.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Program.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..99c66e66ee02b036ec0fb2b783dfa0d1acb6aa97
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/Program.cs"
@@ -0,0 +1,98 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ConsoleApp14
+{
+ class Program
+ {
+ static void Main(string[] args)
+ {
+ Console.WriteLine("---------------欢 迎 进 入 英 雄 联 盟 猜 拳 游 戏--------------");
+ Console.WriteLine();
+ Console.WriteLine("*********************猜拳开始***********************");
+ Console.WriteLine();
+ Console.WriteLine("出拳规则:1.剪刀 2.石头 3.布");
+ Console.WriteLine("请输入你的名字");
+ string name = Console.ReadLine();
+ Me me = new Me(name);
+
+ Judgment judgment = new Judgment();
+ Console.WriteLine("请选择你对战的角色:1.迪莫 2.小法 3.亚索");
+ int a = int.Parse(Console.ReadLine());
+ string str = Convert.ToString(a);
+ switch (str)
+ {
+ case "1":
+ str = "迪莫";
+ break;
+ case "2":
+ str = "小法";
+ break;
+ case "3":
+ str = "亚索";
+ break;
+ default:
+ break;
+ }
+
+ Mdf mdf = new Mdf(name,str);
+ switch (a)
+ {
+ case 1:
+ Console.WriteLine("{0} vs 迪莫", name);
+ dong(ad,mdf,judgment);
+ break;
+ case 2:
+ Console.WriteLine("{0} vs 小法", name);
+ dong(ad, mdf, judgment);
+ break;
+ case 3:
+ Console.WriteLine("{0} vs 亚索", name);
+ dong(ad, mdf, judgment);
+ break;
+ default:
+ break;
+
+ }
+
+ }
+ public static void dong(Ad ad,Mdf mdf,Judgment judgment)
+ {
+
+ Console.WriteLine("游戏开始吗?
");
+ string str = Console.ReadLine();
+ switch (str)
+ {
+ case "y":
+ dong2(ad, mdf, judgment);
+ break;
+ case "n":
+
+ break;
+ }
+ }
+ public static void dong2(Ad ad, Mdf mdf, Judgment judgment) {
+ while (true)
+ {
+ int p1 = ad.Test1();
+ int p2 = mdf.NPC1();
+ judgment.Date(p1,p2);
+ Console.WriteLine("是否进行下一轮?");
+ string str = Console.ReadLine();
+ switch (str)
+ {
+ case "y":
+ dong2(ad, mdf, judgment);
+ break;
+ case "n":
+ judgment.Date1();
+ break;
+ }
+ break;
+ }
+ }
+ }
+ }
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..2f5eda8f267bb17782d18860f9098f2e10d95656
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..60fd09a5cbfc6b5c669131da58c34f942256d2a0
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.cs"
@@ -0,0 +1,32 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+
+ if (TextBox1.Text != null)
+ {
+ Session["name"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..825b957b54fa3764ba61665b55752e67193f5882
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..b31143ec7158308c6d8a7a7a98dcd1a2aecad630
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"] != null)
+ {
+ if (Application["ChatRoom"] == null)
+ {
+ Application["ChatRoom"] = new Panel();
+ }
+ Panel1.Controls.Add((Panel)Application["ChatRoom"]);
+ }
+ else
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = (string)Session["name"];
+ string text = TextBox1.Text;
+ string time = DateTime.Now.ToString();
+
+
+ Literal literal1 = new Literal();
+
+ literal1.Text = time + " " + name + ":" + "
" + text + "
" + "
";
+ ((Panel)Application["ChatRoom"]).Controls.Add(literal1);
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/.keep" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..ec8d950c0d1daf58d0280749dc720faeebbb8333
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..815bdbdef1bef19322a5611176b45e03e58c09ad
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx.cs"
@@ -0,0 +1,27 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ if (!string.IsNullOrWhiteSpace(name))
+ {
+ Session["UserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..1dd55e9a5ae2aec68ce8428fe35c951f1caec60f
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm2.aspx"
@@ -0,0 +1,28 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..e487d32a5bd7ba41117684b1cf4e21d1c8508048
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm2.aspx.cs"
@@ -0,0 +1,47 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["UserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else if (Application["chatRoom"] == null)
+ {
+ Application["chatRoom"] = new Panel();
+ }
+ this.Panel1.Controls.Add((Panel)Application["chatRoom"]);
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["UserName"].ToString();
+ string time = DateTime.Now.ToString();
+ string str = TextBox1.Text;
+ Literal literal = new Literal();
+ literal.Text = name + " " + time + " " + str;
+ ((Panel)(Application["chatRoom"])).Controls.Add(literal);
+
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Session.Abandon();
+ Response.Redirect("WebForm1.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..8ec714231e34857a9e904ee815adfbd2b54cd6dd
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx"
@@ -0,0 +1,18 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..d4b8d193ec35e74164dbd76f7dc6d59c351dfb4e
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ Session["name"] = name;
+ Response.Redirect("webForm2.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..8ce22d630222e68dc56364d1fb674d6794d1a690
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx"
@@ -0,0 +1,25 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication1.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx.cs" "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..6f0e49a55d9012a036e871f395cf7d9c2cc410e3
--- /dev/null
+++ "b/\347\254\2545\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm2.aspx.cs"
@@ -0,0 +1,50 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["name"]!=null)
+ {
+ if (Application["room"]==null)
+ {
+
+ Application["room"] = new Panel();
+
+ }
+ this.Panel1.Controls.Add((Panel) Application["room"]);
+
+
+ }
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Session["name"].ToString();
+ string text = TextBox1.Text;
+ string time = DateTime.Now.ToString();
+ Label label = new Label();
+ label.Text = name + " " + text + " " + time;
+ ((Panel)(Application["room"])).Controls.Add(label);//发送
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Page_Load(sender, e);//刷新
+ }
+
+ protected void Button3_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("webFrom.aspx");//退出
+ Session.Abandon();
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7e2ccf441da15509e5716bb20aa6e897d3edf00a
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx"
@@ -0,0 +1,21 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..00ab9659be50ef6172e816cda735cf101a802b3b
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\344\275\225\351\223\255\346\266\233/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql, sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..01837160c740b21a569c8e1994eb294d4a5a3a3d
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..224f3f61f7eb449519ad24bb8b202ab7819b4f5f
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\205\260\351\246\250\345\204\277/WebForm1.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ private SqlHelper sqlHelper = new SqlHelper();
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string constr = "server=.;uid=sa;pwd=123456;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+ con.Open();
+ string sql = "select*from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+ }
+ }
+ }
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..f716685c95a1a281e1021ae5a58aca4658b77744
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication9.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..d8476ec686b44eb01ac8c523e64f3a6b685eb4b4
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm1.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication9
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+
+
+
+ //private SqlHelper sqlHelper = new SqlHelper();
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string constr = "server=.;uid=sa;pwd=123456;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+ con.Open();
+ string sql = "select*from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..df951bce5bfe220dcbe3e08eb20b411c62036b65
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication9.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..6d461d00b3e9b5baa04404912f0053257681c4b4
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\200\235\347\233\210/WebForm2.aspx.cs"
@@ -0,0 +1,17 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication9
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..8a22db2fa7b57102f9fa0eb7f4b04e82b0f06f59
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c9512dfbcd4512bb7e56eaa923876e9fa5dc4d97
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\257\205/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql,sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Login.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Login.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..a19b1f3f4c146bf16c2fb5ae58c3b76e6f5bd512
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Login.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Login.aspx.cs" Inherits="WebApplication3.Login" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Login.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Login.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..0c9cb3071504952ddef1f0965107faf4397abfe7
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Login.aspx.cs"
@@ -0,0 +1,41 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class Login : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string psw = TextBox2.Text;
+ string sql = "select*from StudentInfo where stu_name=@name and password=@psw";
+ SqlParameter[] spar =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@psw", psw)
+ };
+ DataTable dtbl = Sqlsever.Get(sql, spar);
+ if (dtbl.Rows.Count > 0)
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect(".aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Sqlsever.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Sqlsever.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..e58ac32ef4e6280bc656a7737470cb0a9b08d763
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Sqlsever.cs"
@@ -0,0 +1,51 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+
+namespace WebApplication3
+{
+ public class Sqlsever
+ {
+ private string address = "sever=LAPTOP-CEEAUKFH;database=Userzh_db";
+ private SqlConnection scn = null;
+ public Sqlsever()
+ {
+ scn = new SqlConnection(address);
+ }
+ ///
+ /// 执行调查
+ ///
+ public DataTable Get(string sql, SqlParameter[] spam)
+ {
+ try
+ {
+ if (scn.State == ConnectionState.Closed)
+ {
+ scn.Open();
+ }
+ SqlCommand scmd = new SqlCommand(sql,scn);
+ if (spam != null)
+ {
+ scmd.Parameters.AddRange(spam);
+ }
+ //SqlDataAdapter sdapt = new SqlDataAdapter(scmd);
+ //DataSet dst = new DataSet();
+ //sdapt.Fill(dst);
+ //return dst.Tables[0];
+ return scmd.ExecuteNonQuery() > 0 ? true : false;
+ }
+ catch (Exception ex)
+ { }
+ finally
+ {
+ if (scn != null)
+ {
+ scn.Close();//释放资源
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Zhuce.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Zhuce.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..c550e17b2d43c2bf59ab580f7a916ce540e67a10
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Zhuce.aspx"
@@ -0,0 +1,21 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Zhuce.aspx.cs" Inherits="WebApplication3.Zhuce" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Zhuce.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Zhuce.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..32b3ad4ea0100db55d1bade102edfea4242791f3
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\210\230\346\261\211\346\226\207/Zhuce.aspx.cs"
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class Zhuce : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..301a558287f8193b9d46522fac34175637e408a0
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..1a518b165499c391abb8124307efa3ab4059f705
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = Sa;pwd = 123456; database = Student";
+
+ SqlConnection sqlcon = new SqlConnection(server);
+
+ sqlcon.Open();
+
+ string sql = "select * from StudenInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter(" @pwd" ,pwd),
+
+ };
+
+ SqlCommand sqlC = new SqlCommand(sql, sqlcon);
+
+ if (pras!= null)
+ {
+ sqlC.Parameters.AddRange(pras);
+ }
+ SqlDataReader sqlData = sqlC.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrenUsername"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2c076f2cf778b3c06b4c823ff20e866f6b8b33d8
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\214\205\346\254\243\345\246\202/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..8a22db2fa7b57102f9fa0eb7f4b04e82b0f06f59
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c9512dfbcd4512bb7e56eaa923876e9fa5dc4d97
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\347\234\237/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql,sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/.keep" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/Login.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/Login.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..508cf92da94752e91b494eec410e8d2b6c0a07dc
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/Login.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Login.aspx.cs" Inherits="WebApplication2.Login" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/Login.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/Login.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..aadeafe0fc82fe8141afc6e6a6cd4ef6e473b8a2
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/Login.aspx.cs"
@@ -0,0 +1,19 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class Login : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ //string username = Request.QueryString["name"];
+ string username = Request.Form["TextBox1"];
+ Response.Write(username+"欢迎你");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..3819b891344131abef6a087e542d59788eef592d
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/WebForm1.aspx"
@@ -0,0 +1,29 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..784de129239571515938fbadc23f308da9eb3b39
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\217\266\351\242\200/\347\231\273\345\275\225/WebForm1.aspx.cs"
@@ -0,0 +1,49 @@
+using System;
+using System.Collections.Generic;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ //Response.Redirect($"Login.aspx?name={name}");
+ string constr = "server=.;uid=gao;pwd=123;database=Student_db"; //数据库连接串的编写
+ SqlConnection sqlcon = new SqlConnection(constr); //SqlConnection 类与数据库连接
+ sqlcon.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd"; //查询的内容 @为标记的内容
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+
+ SqlCommand cmd = new SqlCommand(sql, sqlcon);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader(); //查询
+ if (sdr.Read())
+ {
+ Literal1.Text = "登录成功去看看吧";
+
+ }
+ else
+ {
+ Literal1.Text = "登录失败";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/SQL.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/SQL.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..cfda832b36682b6e940cc3d245bf74563d4bea0d
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/SQL.cs"
@@ -0,0 +1,80 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+
+namespace WebApplication9
+{
+ public class SQL
+ {
+ private static string constr = "server=.;uid=sa;pwd=123456;database=Student_db";
+ private SqlConnection con = null;
+
+ public SQL()
+ {
+ con = new SqlConnection(constr);
+ }
+ public DataTable Get(string sql, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+ SqlCommand cmd = new SqlCommand(sql, con);
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+
+ SqlDataAdapter adapter = new SqlDataAdapter(cmd);
+ DataSet ds = new DataSet();
+ adapter.Fill(ds);
+
+ return ds.Tables[0];
+ }
+ catch (Exception ex)
+ {
+ throw new Exception(ex.Message);
+ }
+ finally
+ {
+ if (con != null)
+ {
+ con.Close();
+ }
+ }
+ }
+ public bool Execute(string sql, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+ SqlCommand cmd = new SqlCommand(sql, con);
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+
+ return cmd.ExecuteNonQuery() > 0 ? true : false;
+ }
+ catch (Exception ex)
+ {
+ throw new Exception(ex.Message);
+ }
+ finally
+ {
+ if (con != null)
+ {
+ con.Close();
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..99e6317254a55925224e85d79faf899f739fa780
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication9.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..58c9570483e7d8a292951f59f5d7ff52a8059482
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm1.aspx.cs"
@@ -0,0 +1,44 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication9
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ private SQL sQL = new SQL();
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+
+ DataTable dt = sQL.Get(sql, pars);
+ if (dt.Rows.Count > 0)
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..df951bce5bfe220dcbe3e08eb20b411c62036b65
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication9.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..ff402d6d5ebbdc1ff26f02dcf80452c2497ac849
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\220\264\344\276\235\346\266\265/WebForm2.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication9
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["CurrentUserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else
+ {
+ Response.Write($"你好:,{Session["CurrentUserName"]}
");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..c8a6a99aa0bc183f49aa7fa481cbbcaa645befd0
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm1.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication7.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..43280a430601968e98c3885ef98a0ba66bed111f
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx"
@@ -0,0 +1,25 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication7.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..db0b158a45afcba1741c7cb27804dfaee432371d
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\221\250\346\230\237\345\256\207/WebForm2.aspx.cs"
@@ -0,0 +1,17 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication7
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..860601736524f893f242915324d135cc5feb2c13
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string constr = "server=.;uid=;pwd=;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+
+ con.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx.s1.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx.s1.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..b88efee723b76553d09fef7d28e6b06f7187de37
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\224\220\345\207\241\350\276\211/WebForm1.aspx.s1.cs"
@@ -0,0 +1,71 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication4
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Literal1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Literal Literal1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..860601736524f893f242915324d135cc5feb2c13
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string constr = "server=.;uid=;pwd=;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+
+ con.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..b88efee723b76553d09fef7d28e6b06f7187de37
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\225\206\350\265\242\346\227\255/WebForm1.aspx.designer.cs"
@@ -0,0 +1,71 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication4
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Literal1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Literal Literal1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..728ce4a025958d094c7a3c42eea25a651383228b
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication12.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..9d9cc3ae19e826db6fc2d75f8541c99f418e7b31
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx.cs"
@@ -0,0 +1,17 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication12
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\351\221\253/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\351\221\253/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..8a22db2fa7b57102f9fa0eb7f4b04e82b0f06f59
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\351\221\253/WebForm1.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\351\221\253/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\351\221\253/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c9512dfbcd4512bb7e56eaa923876e9fa5dc4d97
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\274\240\351\221\253/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql,sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..860601736524f893f242915324d135cc5feb2c13
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\345\276\220\351\252\217\351\271\217/WebForm1.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string constr = "server=.;uid=;pwd=;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+
+ con.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/SQLHelp.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/SQLHelp.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..24f8ce599d3ca506ef6dfe5d9b492c6bb506daee
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/SQLHelp.cs"
@@ -0,0 +1,87 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+
+namespace WebApplication2
+{
+ public class SQLHelp
+ {
+ private static string constr = server=.;uid=sa;pwd=123456;database=Student_db;
+ private SqlConnection con = null;
+ public SQLHelp()
+ {
+ con = new SqlConnection(constr);
+ }
+
+ public DataTable Get(string sql, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand(sql, con);
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+
+ SqlDataAdapter sda = new SqlDataAdapter(cmd);
+ DataSet ds = new DataSet();
+
+ sda.Fill(ds);
+
+ return ds.Tables[0];
+ }
+ catch (Exception a)
+ {
+
+ throw new Exception(a.Message);
+ }
+ finally
+ {
+ if (con == null)
+ {
+ con.Close();
+ }
+ }
+
+ }
+ public bool A(string constr, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand();
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+ return cmd.ExecuteNonQuery() 0 true false;
+ }
+ catch (Exception A)
+ {
+
+ throw new Exception(A.Message);
+ }
+ finally
+ {
+ if (con != null)
+ {
+ con.Close();
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..860601736524f893f242915324d135cc5feb2c13
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\226\275\346\261\237\345\263\260/WebForm1.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string constr = "server=.;uid=;pwd=;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+
+ con.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7e2ccf441da15509e5716bb20aa6e897d3edf00a
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm1.aspx"
@@ -0,0 +1,21 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..00ab9659be50ef6172e816cda735cf101a802b3b
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\345\255\220\346\272\220/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql, sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Login.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Login.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..e9fe490108e4c14c644062c3cc07c36d02d94b6b
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Login.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Login.aspx.cs" Inherits="WebApplication3.Login" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Login.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Login.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..0c9cb3071504952ddef1f0965107faf4397abfe7
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Login.aspx.cs"
@@ -0,0 +1,41 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class Login : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string psw = TextBox2.Text;
+ string sql = "select*from StudentInfo where stu_name=@name and password=@psw";
+ SqlParameter[] spar =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@psw", psw)
+ };
+ DataTable dtbl = Sqlsever.Get(sql, spar);
+ if (dtbl.Rows.Count > 0)
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect(".aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Sqlsever.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Sqlsever.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..e58ac32ef4e6280bc656a7737470cb0a9b08d763
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Sqlsever.cs"
@@ -0,0 +1,51 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+
+namespace WebApplication3
+{
+ public class Sqlsever
+ {
+ private string address = "sever=LAPTOP-CEEAUKFH;database=Userzh_db";
+ private SqlConnection scn = null;
+ public Sqlsever()
+ {
+ scn = new SqlConnection(address);
+ }
+ ///
+ /// 执行调查
+ ///
+ public DataTable Get(string sql, SqlParameter[] spam)
+ {
+ try
+ {
+ if (scn.State == ConnectionState.Closed)
+ {
+ scn.Open();
+ }
+ SqlCommand scmd = new SqlCommand(sql,scn);
+ if (spam != null)
+ {
+ scmd.Parameters.AddRange(spam);
+ }
+ //SqlDataAdapter sdapt = new SqlDataAdapter(scmd);
+ //DataSet dst = new DataSet();
+ //sdapt.Fill(dst);
+ //return dst.Tables[0];
+ return scmd.ExecuteNonQuery() > 0 ? true : false;
+ }
+ catch (Exception ex)
+ { }
+ finally
+ {
+ if (scn != null)
+ {
+ scn.Close();//释放资源
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Zhuce.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Zhuce.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..1f760ff7b372b83871b5daf1c350f4855860f90f
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Zhuce.aspx"
@@ -0,0 +1,19 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Zhuce.aspx.cs" Inherits="WebApplication3.Zhuce" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Zhuce.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Zhuce.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..32b3ad4ea0100db55d1bade102edfea4242791f3
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\216\346\230\214\345\256\235/Zhuce.aspx.cs"
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class Zhuce : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/Login.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/Login.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..2fd29a6e34672e50c613ce8b20ed13c2744ed9ca
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/Login.aspx"
@@ -0,0 +1,25 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Login.aspx.cs" Inherits="WebApplication14.Login" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/Login.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/Login.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..0350bc48ff7b291f707bc5ed00d2bc68022042a0
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/Login.aspx.cs"
@@ -0,0 +1,63 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication14
+{
+ public partial class Login : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ //第一步:新建连接对象
+ SqlConnection connection = new SqlConnection();
+ //第二步:给连接对象指定连接的参数(连接字符串)
+ connection.ConnectionString = "Data Source = localhost; Initial Catalog = Student; Integrated Security = SSPI;";
+ //第三步:开始建立连接
+ connection.Open();//Open函数用于打开数据库连接
+ //第四步:输出提示
+ if (connection.State == System.Data.ConnectionState.Open)
+ {
+ Response.Write("");
+ }
+ else
+ {
+ Response.Write("");
+ }
+ //注入
+ string sql = "select * from zm where UserName=@name and Password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+
+ SqlCommand cmd = new SqlCommand(sql,connection);
+ cmd.Parameters.AddRange(pars);
+
+ //数据读取器
+ SqlDataReader sdr = cmd.ExecuteReader();//查询
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("WebForm1.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..426b5d6de00e91cc5160a59fb7a8564fc7a99423
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication14.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..b4bf3d716bf112fe483f5881bca3232f3910f829
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\344\270\260\350\261\252/WebForm1.aspx.cs"
@@ -0,0 +1,17 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication14
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/.keep" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/SQLHelp.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/SQLHelp.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..270f9011d4321dc04a14a779c57792632aefeac1
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/SQLHelp.cs"
@@ -0,0 +1,87 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+
+namespace WebApplication2
+{
+ public class SQLHelp
+ {
+ private static string constr = "server=.;uid=sa;pwd=123456;database=Student_db";
+ private SqlConnection con = null;
+ public SQLHelp()
+ {
+ con = new SqlConnection(constr);
+ }
+
+ public DataTable Get(string sql, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand(sql, con);
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+
+ SqlDataAdapter sda = new SqlDataAdapter(cmd);
+ DataSet ds = new DataSet();
+
+ sda.Fill(ds);
+
+ return ds.Tables[0];
+ }
+ catch (Exception a)
+ {
+
+ throw new Exception(a.Message);
+ }
+ finally
+ {
+ if (con == null)
+ {
+ con.Close();
+ }
+ }
+
+ }
+ public bool A(string constr, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand();
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+ return cmd.ExecuteNonQuery() > 0 ? true : false;
+ }
+ catch (Exception A)
+ {
+
+ throw new Exception(A.Message);
+ }
+ finally
+ {
+ if (con != null)
+ {
+ con.Close();
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..afcf596cd3c64e831b73a534d73625dd09fdce54
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx"
@@ -0,0 +1,25 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..d982a71c9919e7702c5caa2d49050407c2dfe655
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.cs"
@@ -0,0 +1,45 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ private SQLHelp sqlhelp = new SQLHelp();
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string password = TextBox2.Text;
+ string sql = "selsec * from StudentInfo where stu_name = @name and password = @password";
+
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@password", password)
+ };
+
+ DataTable dt = sqlhelp.Get(sql, pars);
+
+ if (dt.Rows.Count > 0)
+ {
+ Session["CurrenUserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..499cb0bda27ca55afebe1f7e4a1e3480418f4ee0
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Literal1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Literal Literal1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..2cd8ec6155027cd65c2673f7c4745b7835a1a641
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f5ba175f41c360b17f2e260f1d1dbf9f0d6b4df8
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.cs"
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+
+
+ if(Session["CurrentUserName"] == null)
+ {
+ Response.Redirect("Login.aspx");
+ }
+ else
+ {
+ string name = (string)Session["CurrentUserName"];
+ Response.Write($"登录成功!{name}欢迎!
");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..249cc1aabbe6005fd5ab749a0ff8d517f3113a28
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\235\250\345\270\206/WebForm2.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\236\227\344\275\263\345\205\203/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\236\227\344\275\263\345\205\203/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..8a22db2fa7b57102f9fa0eb7f4b04e82b0f06f59
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\236\227\344\275\263\345\205\203/WebForm1.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\236\227\344\275\263\345\205\203/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\236\227\344\275\263\345\205\203/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c9512dfbcd4512bb7e56eaa923876e9fa5dc4d97
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\236\227\344\275\263\345\205\203/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql,sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/home.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/home.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..2348529f25bb35b7210dd2995f339d62a44d46f2
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/home.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="home.aspx.cs" Inherits="WebApplication4.home" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/home.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/home.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..97af918ec238d8ac69ebb7d31b78d3cb23a16728
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/home.aspx.cs"
@@ -0,0 +1,23 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class home : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["username"] == null)
+ {
+ Response.Redirect("login.aspx");
+ }
+ else {
+ Response.Write($"hi,{Session["username"]}
");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/login.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/login.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..f4192237f43cabd9da3861fb4b14385f9a260ebc
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/login.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="login.aspx.cs" Inherits="WebApplication4.login" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/login.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/login.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..33aaf1c949d3db2a9ea9e2202f060983d54974dc
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/login.aspx.cs"
@@ -0,0 +1,52 @@
+using System;
+using System.Collections.Generic;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class login : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string constr = "server=.;uid=sa;pwd=123;database=student_db";
+ SqlConnection con = new SqlConnection(constr);
+ con.Open();
+ string sql = "select * from studentinfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars = {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+ SqlCommand cmd = new SqlCommand(sql,con);
+ cmd.Parameters.AddRange(pars);
+ int result = cmd.ExecuteNonQuery();
+ cmd.ExecuteScalar();
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["username"] = name;
+ Response.Redirect("home.aspx");
+
+ }
+ else {
+ Label1.Text = "登录失败";
+ }
+ }
+
+ protected void Button2_Click(object sender, EventArgs e)
+ {
+ Response.Redirect("register.aspx");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/register.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/register.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..9d3814145fb30f3876d7b2b9b0e6f0ff41ba82cc
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/register.aspx"
@@ -0,0 +1,29 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="register.aspx.cs" Inherits="WebApplication4.register" %>
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/register.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/register.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f517dfd41b42cdcf8f050d19a112387c14957f08
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\346\270\251\345\271\277\347\224\237/register.aspx.cs"
@@ -0,0 +1,49 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class register : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string email = TextBox3.Text;
+ string sex= RadioButton1.Checked?"1":"0";
+ string conster = "server=.;uid=sa;pwd=123;database=student_db";
+ SqlConnection con = new SqlConnection(conster);
+ con.Open();
+ string sql = "insert into StudentInfo (stu_name,email,gender,[password]) values (@name,@email,@gender,@pwd)";
+ SqlParameter[] pars = {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ new SqlParameter("@email",email),
+ new SqlParameter("@sex",sex),
+ };
+ SqlCommand cmd = new SqlCommand(sql,con);
+ cmd.Parameters.AddRange(pars);
+ int re = cmd.ExecuteNonQuery();
+ if (sqlHelper.Execute(sql, pars))
+ {
+ Literal1.Text = "注册成功!去登陆";
+ }
+ else
+ {
+ Literal1.Text = "注册失败!";
+ }
+
+
+
+
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..8a22db2fa7b57102f9fa0eb7f4b04e82b0f06f59
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c9512dfbcd4512bb7e56eaa923876e9fa5dc4d97
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\206\212\346\226\207\351\221\253/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql,sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..860601736524f893f242915324d135cc5feb2c13
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string constr = "server=.;uid=;pwd=;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+
+ con.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..b88efee723b76553d09fef7d28e6b06f7187de37
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\216\213\351\200\270\351\243\236/WebForm1.aspx.designer.cs"
@@ -0,0 +1,71 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication4
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Literal1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Literal Literal1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/.keep" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/SQLHelp.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/SQLHelp.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..270f9011d4321dc04a14a779c57792632aefeac1
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/SQLHelp.cs"
@@ -0,0 +1,87 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+
+namespace WebApplication2
+{
+ public class SQLHelp
+ {
+ private static string constr = "server=.;uid=sa;pwd=123456;database=Student_db";
+ private SqlConnection con = null;
+ public SQLHelp()
+ {
+ con = new SqlConnection(constr);
+ }
+
+ public DataTable Get(string sql, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand(sql, con);
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+
+ SqlDataAdapter sda = new SqlDataAdapter(cmd);
+ DataSet ds = new DataSet();
+
+ sda.Fill(ds);
+
+ return ds.Tables[0];
+ }
+ catch (Exception a)
+ {
+
+ throw new Exception(a.Message);
+ }
+ finally
+ {
+ if (con == null)
+ {
+ con.Close();
+ }
+ }
+
+ }
+ public bool A(string constr, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand();
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+ return cmd.ExecuteNonQuery() > 0 ? true : false;
+ }
+ catch (Exception A)
+ {
+
+ throw new Exception(A.Message);
+ }
+ finally
+ {
+ if (con != null)
+ {
+ con.Close();
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..afcf596cd3c64e831b73a534d73625dd09fdce54
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx"
@@ -0,0 +1,25 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..d982a71c9919e7702c5caa2d49050407c2dfe655
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx.cs"
@@ -0,0 +1,45 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ private SQLHelp sqlhelp = new SQLHelp();
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string password = TextBox2.Text;
+ string sql = "selsec * from StudentInfo where stu_name = @name and password = @password";
+
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@password", password)
+ };
+
+ DataTable dt = sqlhelp.Get(sql, pars);
+
+ if (dt.Rows.Count > 0)
+ {
+ Session["CurrenUserName"] = name;
+ Response.Redirect("WebForm2.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..499cb0bda27ca55afebe1f7e4a1e3480418f4ee0
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Literal1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Literal Literal1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..2cd8ec6155027cd65c2673f7c4745b7835a1a641
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx"
@@ -0,0 +1,17 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f5ba175f41c360b17f2e260f1d1dbf9f0d6b4df8
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx.cs"
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+
+
+ if(Session["CurrentUserName"] == null)
+ {
+ Response.Redirect("Login.aspx");
+ }
+ else
+ {
+ string name = (string)Session["CurrentUserName"];
+ Response.Write($"登录成功!{name}欢迎!
");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..249cc1aabbe6005fd5ab749a0ff8d517f3113a28
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\347\275\227\344\273\225\345\244\251/WebForm2.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/.keep" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..ba141d50d96b5b0ad3f64b276094ebdd5addf3c2
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx"
@@ -0,0 +1,23 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..cc22d530a42f4e1e0f433e1ea6508b74295b87d7
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\344\270\234\347\224\237/WebForm1.aspx.cs"
@@ -0,0 +1,56 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string constr = "server=.;uid=sa;pwd=123456;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+ con.Open();
+ string name = TextBox1.Text;
+ string pass = TextBox2.Text;
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+{
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pass)
+ };
+
+
+ SqlCommand sqlCommand = new SqlCommand();
+
+ sqlCommand.Parameters.AddRange(pars);
+
+ int s = sqlCommand.ExecuteNonQuery();
+
+ sqlCommand.ExecuteScalar();
+
+
+
+ SqlDataReader sqlData = sqlCommand.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("登录成功");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7e2ccf441da15509e5716bb20aa6e897d3edf00a
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx"
@@ -0,0 +1,21 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..00ab9659be50ef6172e816cda735cf101a802b3b
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\224\241\345\256\227\351\225\207/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql, sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..1b0e85918a9166d5e3f6fca63b312d7fb2c49342
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..605cd119078ddfc0753cbb76a0838271d896cebd
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\345\237\271\346\250\237/WebForm1.aspx.cs"
@@ -0,0 +1,55 @@
+using System;
+using System.Collections.Generic;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+
+ string name = TextBox1.Text;
+ string password = TextBox2.Text;
+ SqlConnection sqlCt = new SqlConnection();
+ sqlCt.ConnectionString = "Data Source = LAPTOP - VRL0O07U; Initial Catalog = Student; Integrated Security = SSPI;";
+
+ sqlCt.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @password";
+ SqlParameter[] pra =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",password),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql, sqlCt);
+
+ if (pra != null)
+ {
+ sqlCom.Parameters.AddRange(pra);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..301a558287f8193b9d46522fac34175637e408a0
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx"
@@ -0,0 +1,20 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..1a518b165499c391abb8124307efa3ab4059f705
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = Sa;pwd = 123456; database = Student";
+
+ SqlConnection sqlcon = new SqlConnection(server);
+
+ sqlcon.Open();
+
+ string sql = "select * from StudenInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter(" @pwd" ,pwd),
+
+ };
+
+ SqlCommand sqlC = new SqlCommand(sql, sqlcon);
+
+ if (pras!= null)
+ {
+ sqlC.Parameters.AddRange(pras);
+ }
+ SqlDataReader sqlData = sqlC.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrenUsername"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..2c076f2cf778b3c06b4c823ff20e866f6b8b33d8
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\256\270\350\207\252\346\246\225/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication1
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Label1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label Label1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..8a22db2fa7b57102f9fa0eb7f4b04e82b0f06f59
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..c9512dfbcd4512bb7e56eaa923876e9fa5dc4d97
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\350\265\265\345\230\211\351\252\217/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql,sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..feb9120f8b97cde79663b623f6eccbfec76ccc82
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx"
@@ -0,0 +1,37 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..bc9956595a212bb5525b1b18543507622a9c29fd
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\202\271\346\265\267\345\205\265/WebForm1.aspx.cs"
@@ -0,0 +1,63 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = LAPTOP-9LFBV2BF;uid = Montian;pwd = ;database = Student_db";
+ SqlConnection sqlcon = new SqlConnection(server);
+ sqlcon.Open();
+
+ string sql = "select * from StudentInfo where stu_name=@name and stu_password=@pwd";
+
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@password",pwd)
+ };
+ SqlCommand sqlCom = new SqlCommand(sql, sqlcon);
+ sqlCom.Parameters.AddRange(pars);
+
+ SqlDataReader sdr = sqlCom.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+
+ //DataTable dt = sql.Get(sql, pars);
+ //if (dt.Rows.Count > 0)
+ //{
+ // Session["CurrentUserName"] = name;
+ // Response.Redirect("Home.aspx");
+ //}
+ //else
+ //{
+ // Literal1.Text = "登录失败!";
+ //}
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Login.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Login.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..a19b1f3f4c146bf16c2fb5ae58c3b76e6f5bd512
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Login.aspx"
@@ -0,0 +1,22 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Login.aspx.cs" Inherits="WebApplication3.Login" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Login.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Login.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..0c9cb3071504952ddef1f0965107faf4397abfe7
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Login.aspx.cs"
@@ -0,0 +1,41 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class Login : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string psw = TextBox2.Text;
+ string sql = "select*from StudentInfo where stu_name=@name and password=@psw";
+ SqlParameter[] spar =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@psw", psw)
+ };
+ DataTable dtbl = Sqlsever.Get(sql, spar);
+ if (dtbl.Rows.Count > 0)
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect(".aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Sqlsever.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Sqlsever.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..e58ac32ef4e6280bc656a7737470cb0a9b08d763
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Sqlsever.cs"
@@ -0,0 +1,51 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+
+namespace WebApplication3
+{
+ public class Sqlsever
+ {
+ private string address = "sever=LAPTOP-CEEAUKFH;database=Userzh_db";
+ private SqlConnection scn = null;
+ public Sqlsever()
+ {
+ scn = new SqlConnection(address);
+ }
+ ///
+ /// 执行调查
+ ///
+ public DataTable Get(string sql, SqlParameter[] spam)
+ {
+ try
+ {
+ if (scn.State == ConnectionState.Closed)
+ {
+ scn.Open();
+ }
+ SqlCommand scmd = new SqlCommand(sql,scn);
+ if (spam != null)
+ {
+ scmd.Parameters.AddRange(spam);
+ }
+ //SqlDataAdapter sdapt = new SqlDataAdapter(scmd);
+ //DataSet dst = new DataSet();
+ //sdapt.Fill(dst);
+ //return dst.Tables[0];
+ return scmd.ExecuteNonQuery() > 0 ? true : false;
+ }
+ catch (Exception ex)
+ { }
+ finally
+ {
+ if (scn != null)
+ {
+ scn.Close();//释放资源
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Zhuce.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Zhuce.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..c550e17b2d43c2bf59ab580f7a916ce540e67a10
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Zhuce.aspx"
@@ -0,0 +1,21 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Zhuce.aspx.cs" Inherits="WebApplication3.Zhuce" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Zhuce.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Zhuce.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..32b3ad4ea0100db55d1bade102edfea4242791f3
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\221\347\276\216\345\251\267/Zhuce.aspx.cs"
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication3
+{
+ public partial class Zhuce : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/Home.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/Home.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..4c1fabebfa51892604c3f4842622a0bab34e00f1
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/Home.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Home.aspx.cs" Inherits="WebApplication4.Home" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/Home.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/Home.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..675bee0e8ca47e720f3117691fc5866ceb945cc4
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/Home.aspx.cs"
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class Home : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (Session["CurrentUserName"] == null)
+ {
+ Response.Redirect("WebForm1.aspx");
+ }
+ else
+ {
+ Response.Write($"欢迎你,{Session["CurrentUserName"]}
");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/Home.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/Home.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..e27467aaee467e561fdbd34e78ba0a5ba7de1cdd
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/Home.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication4
+{
+
+
+ public partial class Home
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..977c9b7efb6aecab361fd081594a773732fc941c
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx"
@@ -0,0 +1,24 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication4.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..947d1339c831cf0f0c2f05ba9c9924012d05484a
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.cs"
@@ -0,0 +1,54 @@
+using System;
+using System.Collections.Generic;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = Username.Text;
+ string pwd = Password.Text;
+
+ string constr = " Data Source = LAPTOP-DJIQEFJT ; Initial Catalog = Student_db ; Integrate Security = True";
+ SqlConnection con = new SqlConnection(constr);
+
+ con.Open();
+
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd", pwd)
+ };
+
+ SqlCommand cmd = new SqlCommand(sql,con);
+ cmd.Parameters.AddRange(pars);
+
+ int result = cmd.ExecuteNonQuery();
+
+ cmd.ExecuteScalar();
+
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登陆失败";
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..9c845a018015141bd2719780af7f25e2f1a20ad1
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\203\255\347\220\252\346\236\253/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication4
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// Username 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox Username;
+
+ ///
+ /// Password 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox Password;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Literal1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Literal Literal1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/SQLHelp.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/SQLHelp.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..270f9011d4321dc04a14a779c57792632aefeac1
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/SQLHelp.cs"
@@ -0,0 +1,87 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+
+namespace WebApplication2
+{
+ public class SQLHelp
+ {
+ private static string constr = "server=.;uid=sa;pwd=123456;database=Student_db";
+ private SqlConnection con = null;
+ public SQLHelp()
+ {
+ con = new SqlConnection(constr);
+ }
+
+ public DataTable Get(string sql, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand(sql, con);
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+
+ SqlDataAdapter sda = new SqlDataAdapter(cmd);
+ DataSet ds = new DataSet();
+
+ sda.Fill(ds);
+
+ return ds.Tables[0];
+ }
+ catch (Exception a)
+ {
+
+ throw new Exception(a.Message);
+ }
+ finally
+ {
+ if (con == null)
+ {
+ con.Close();
+ }
+ }
+
+ }
+ public bool A(string constr, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand();
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+ return cmd.ExecuteNonQuery() > 0 ? true : false;
+ }
+ catch (Exception A)
+ {
+
+ throw new Exception(A.Message);
+ }
+ finally
+ {
+ if (con != null)
+ {
+ con.Close();
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..860601736524f893f242915324d135cc5feb2c13
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string constr = "server=.;uid=;pwd=;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+
+ con.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..499cb0bda27ca55afebe1f7e4a1e3480418f4ee0
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Literal1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Literal Literal1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f5ba175f41c360b17f2e260f1d1dbf9f0d6b4df8
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.cs"
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+
+
+ if(Session["CurrentUserName"] == null)
+ {
+ Response.Redirect("Login.aspx");
+ }
+ else
+ {
+ string name = (string)Session["CurrentUserName"];
+ Response.Write($"登录成功!{name}欢迎!
");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..249cc1aabbe6005fd5ab749a0ff8d517f3113a28
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\231\210\346\225\217\351\222\212/WebForm2.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/SQLHelp.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/SQLHelp.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..270f9011d4321dc04a14a779c57792632aefeac1
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/SQLHelp.cs"
@@ -0,0 +1,87 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+
+namespace WebApplication2
+{
+ public class SQLHelp
+ {
+ private static string constr = "server=.;uid=sa;pwd=123456;database=Student_db";
+ private SqlConnection con = null;
+ public SQLHelp()
+ {
+ con = new SqlConnection(constr);
+ }
+
+ public DataTable Get(string sql, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand(sql, con);
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+
+ SqlDataAdapter sda = new SqlDataAdapter(cmd);
+ DataSet ds = new DataSet();
+
+ sda.Fill(ds);
+
+ return ds.Tables[0];
+ }
+ catch (Exception a)
+ {
+
+ throw new Exception(a.Message);
+ }
+ finally
+ {
+ if (con == null)
+ {
+ con.Close();
+ }
+ }
+
+ }
+ public bool A(string constr, SqlParameter[] pars)
+ {
+ try
+ {
+ if (con.State == ConnectionState.Closed)
+ {
+ con.Open();
+ }
+
+ SqlCommand cmd = new SqlCommand();
+
+ if (pars != null)
+ {
+ cmd.Parameters.AddRange(pars);
+ }
+ return cmd.ExecuteNonQuery() > 0 ? true : false;
+ }
+ catch (Exception A)
+ {
+
+ throw new Exception(A.Message);
+ }
+ finally
+ {
+ if (con != null)
+ {
+ con.Close();
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..860601736524f893f242915324d135cc5feb2c13
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.cs"
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication4
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string constr = "server=.;uid=;pwd=;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+
+ con.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..499cb0bda27ca55afebe1f7e4a1e3480418f4ee0
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm1.aspx.designer.cs"
@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm1
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// TextBox1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox1;
+
+ ///
+ /// TextBox2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.TextBox TextBox2;
+
+ ///
+ /// Button1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Button Button1;
+
+ ///
+ /// Literal1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Literal Literal1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..f5ba175f41c360b17f2e260f1d1dbf9f0d6b4df8
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.cs"
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm2 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+
+
+ if(Session["CurrentUserName"] == null)
+ {
+ Response.Redirect("Login.aspx");
+ }
+ else
+ {
+ string name = (string)Session["CurrentUserName"];
+ Response.Write($"登录成功!{name}欢迎!
");
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.designer.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.designer.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..249cc1aabbe6005fd5ab749a0ff8d517f3113a28
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\237\246\346\230\214\345\235\244/WebForm2.aspx.designer.cs"
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace WebApplication2
+{
+
+
+ public partial class WebForm2
+ {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/.keep" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/.keep"
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/Login.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/Login.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..508cf92da94752e91b494eec410e8d2b6c0a07dc
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/Login.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Login.aspx.cs" Inherits="WebApplication2.Login" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/Login.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/Login.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..aadeafe0fc82fe8141afc6e6a6cd4ef6e473b8a2
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/Login.aspx.cs"
@@ -0,0 +1,19 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class Login : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ //string username = Request.QueryString["name"];
+ string username = Request.Form["TextBox1"];
+ Response.Write(username+"欢迎你");
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..3819b891344131abef6a087e542d59788eef592d
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx"
@@ -0,0 +1,29 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..784de129239571515938fbadc23f308da9eb3b39
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\253\230\345\245\225/WebForm1.aspx.cs"
@@ -0,0 +1,49 @@
+using System;
+using System.Collections.Generic;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ //Response.Redirect($"Login.aspx?name={name}");
+ string constr = "server=.;uid=gao;pwd=123;database=Student_db"; //数据库连接串的编写
+ SqlConnection sqlcon = new SqlConnection(constr); //SqlConnection 类与数据库连接
+ sqlcon.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd"; //查询的内容 @为标记的内容
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+
+ SqlCommand cmd = new SqlCommand(sql, sqlcon);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader(); //查询
+ if (sdr.Read())
+ {
+ Literal1.Text = "登录成功去看看吧";
+
+ }
+ else
+ {
+ Literal1.Text = "登录失败";
+ }
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..356cba1281259a38bffdc792f15b16b005cd7ce5
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx"
@@ -0,0 +1,21 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx.cs" "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..1c697d780b2b15d52204a4712e08c40e6673c349
--- /dev/null
+++ "b/\347\254\2546\346\254\241\344\275\234\344\270\232/\351\273\204\345\277\240\347\243\212/WebForm1.aspx.cs"
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication2
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+
+ string server = "server = .;uid = sa;pwd = 123456;database = Student";
+
+ SqlConnection sqlCon = new SqlConnection(server);
+
+ sqlCon.Open();
+
+ string sql = "select * from StudentInfo where stuName = @name and password = @pwd";
+
+ SqlParameter[] pras =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd),
+ };
+
+ SqlCommand sqlCom = new SqlCommand(sql, sqlCon);
+
+ if (pras != null)
+ {
+ sqlCom.Parameters.AddRange(pras);
+ }
+
+ SqlDataReader sqlData = sqlCom.ExecuteReader();
+ if (sqlData.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Label1.Text = "登录成功";
+ }
+ else
+ {
+ Label1.Text = "登录失败";
+ }
+ }
+}
+}
diff --git "a/\347\254\2547\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx" "b/\347\254\2547\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx"
new file mode 100644
index 0000000000000000000000000000000000000000..7d345d6909cab80e8ff0bbf9d526120bde8bcc2a
--- /dev/null
+++ "b/\347\254\2547\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx"
@@ -0,0 +1,16 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git "a/\347\254\2547\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx.cs" "b/\347\254\2547\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx.cs"
new file mode 100644
index 0000000000000000000000000000000000000000..8b5530d3da6709ec725e2989c337a246ec87667a
--- /dev/null
+++ "b/\347\254\2547\346\254\241\344\275\234\344\270\232/\345\274\240\345\256\217/WebForm1.aspx.cs"
@@ -0,0 +1,45 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebApplication1
+{
+ public partial class WebForm1 : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+
+ protected void Button1_Click(object sender, EventArgs e)
+ {
+ string name = TextBox1.Text;
+ string pwd = TextBox2.Text;
+ string constr = "server=.;uid=;pwd=;database=Student_db";
+ SqlConnection con = new SqlConnection(constr);
+
+ con.Open();
+ string sql = "select * from StudentInfo where stu_name=@name and password=@pwd";
+ SqlParameter[] pars =
+ {
+ new SqlParameter("@name",name),
+ new SqlParameter("@pwd",pwd)
+ };
+ SqlCommand cmd = new SqlCommand(sql, con);
+ cmd.Parameters.AddRange(pars);
+ SqlDataReader sdr = cmd.ExecuteReader();
+ if (sdr.Read())
+ {
+ Session["CurrentUserName"] = name;
+ Response.Redirect("Home.aspx");
+ }
+ else
+ {
+ Literal1.Text = "登录失败!";
+ }
+ }
+ }
+}
\ No newline at end of file