ASP.NET 跳转页面数据的获取 (使用html控件)
来源:互联网 发布:网络对传统文化的影响 编辑:程序博客网 时间:2024/06/06 16:57
一:注册界面代码
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Reg.aspx.cs" Inherits="WebApplication2.WebForm1" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
</head>
<body>
<form id="form" method="get" action="Show.aspx">
// 因为使用的是html的form,按下submit按钮的时候自动跳转到action指定的url,至于要跳转到信息验证c#代码,或者是结果代码页面,自主决定
<div>
你的名字
<input type="text" name ="name" />
<br/>
<input type="submit" value="text" />
<br/>
<br/>
</div>
</form>
</body>
</html>
二:结果界面代码
<%@ Page Language="C#" AutoEventWireup="true" enableviewstatemac="false" CodeBehind="Show1.aspx.cs" Inherits="WebApplication2.Show2" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>
<%=name%>
</div>
</form>
</body>
</html>
三:结果界面后台代码
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 Show2 : System.Web.UI.Page
{
public String name = "Wxy";
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
name = Request.Form["name"];
}
}
}
}
- ASP.NET 跳转页面数据的获取 (使用html控件)
- ASP.Net 如何让后台的cs页面获取到前台的html控件的值
- ASP.NET页面的跳转
- ASP.net服务器控件页面跳转兼GirdView数据绑定控件动态传值
- html button 跳转ASP.NET页面跳转技术总结
- Asp.net 中获取html控件的值的方法
- asp.net 获取html控件的值的代码
- Asp.net 中获取html控件的值的方法
- asp.net 中遍历页面里某种控件(Textbox)、获取当前页面的名称
- Asp.net 2.0 中获取控件输出的Html代码
- ASP.NET 中页面获取所用用户控件的事件
- 遍历获取ASP.NET页面控件的名称及值
- ASP.NET页面中获取服务器控件的客户端ID
- asp.net如何获取页面动态生成的服务器控件
- ASP.NET中动态获取数据使用Highcharts图表控件
- asp.net 获取 Html页面源码
- asp.net 如何获取html控件select
- asp.net后台获取html控件值
- shell脚本编程(一)
- php app 接口 封装xml
- 添加实时阴影
- 句柄和指针
- DOM4J 解析XML文件
- ASP.NET 跳转页面数据的获取 (使用html控件)
- 斐波那契数列 1, 1, 2, 3, 5, 8, 13, 21, 34...
- java中不带package和带package的编译运行方式
- 信号的基本概念
- test
- sublime text3下的bootstrap插件
- No CurrentSessionContext configured 沒配置
- 运输层
- stick-learn 朴素贝叶斯的三个常用模型:高斯、多项式、伯努利