<form runat=server/>
再试一下
再试一下
解决方案 »
- 小生不才 谁能帮我逐条解释下这个自定义控件 我实在很菜 谢谢啦
- 关于File取值的问题
- 怎么过滤掉label.text中的不需要的字符?急!在线等!
- 我们定义的类,主要是定义它的一些方法吧??
- 如何在aspx文件中接受html文件的查询条件?
- 继续有问题:ASP.NET MVC4项目传到虚拟机上之后默认路由无法被服务器识别
- 我的这个javascript怎么回事?帮个忙谢谢了
- 数据库邦定问题?在线等待!
- 各位请教一个简单的问题。好久也没有来了,顺便散些分。
- 指向时重新生成一个页面,如何使原页面保留?
- 我的asp.net运行是怎么显示的字体我都不认识,而查看源文件是都认识!!!
- 誰知道如何使用.net中的Web存取模式?
webform1.aspx:<%@ Page language="c#" Codebehind="findpwd.aspx.cs" AutoEventWireup="false" Inherits="myproject.findpwd" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
<HEAD>
<meta content="Microsoft Visual Studio 7.0" name="GENERATOR">
<meta content="C#" name="CODE_LANGUAGE">
<meta content="JavaScript (ECMAScript)" name="vs_defaultClientScript">
<meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
<LINK href="/style.css" rel="stylesheet">
</HEAD>
<body MS_POSITIONING="GridLayout">
<form id="findpwd" action="webform2.aspx" method="post" runat="server">
<asp:textbox id="uname" runat="server"></asp:textbox>
<asp:Button Text="提交" Runat="server" id="Button1"></asp:Button>
</form>
按'提交'按钮后,并没有提交到webform2.aspx页.
按F7编辑findpwd.aspx.cs文件即可
<%@ Page language="c#" Codebehind="WebForm1.aspx.cs" AutoEventWireup="false" Inherits="MyForm.WebForm1" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
<HEAD>
</HEAD>
<body MS_POSITIONING="GridLayout">
<form id="form1" method="post" action="WebForm2.aspx" runat="server">
<asp:TextBox id="TextBox1" style="Z-INDEX: 101; LEFT: 399px; POSITION: absolute; TOP: 160px" runat="server"></asp:TextBox>
<asp:Button id="Button1" type="submit" style="Z-INDEX: 102; LEFT: 451px; POSITION: absolute; TOP: 267px" runat="server" Text="Button"></asp:Button>
</form>
</body>
</HTML>
而得到的html代码是:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
<HEAD>
</HEAD>
<body MS_POSITIONING="GridLayout">
<form name="form1" method="post" action="WebForm1.aspx" id="form1">
<input type="hidden" name="__VIEWSTATE" value="dDwxNDg5OTk5MzM7Oz4=" /> <input name="TextBox1" type="text" id="TextBox1" style="Z-INDEX: 101; LEFT: 399px; POSITION: absolute; TOP: 160px" />
<input type="submit" name="Button1" value="Button" id="Button1" type="submit" style="Z-INDEX: 102; LEFT: 451px; POSITION: absolute; TOP: 267px" />
</form>
</body>
</HTML>
if you acknowledge of it ,you will know to do it!