易截截图软件、单文件、免安装、纯绿色、仅160KB

c# asp.net 获取客户端表单的数据

在web程序中,经常会使用在一个网页使用其他网页提交的数据信息,这里可以使用Request内置对象来完成,来获取用户提交的信息,根据客户端提交数据方式的不同,Request对象分别使用Form和QueryString集合属性来获取数据。下面是两种集合获取方式的不同点:通过Form获取数据时在form属性中简单的添加action=“跳转的网页地址”,<form. ID="id号 " runat=“sever” action=“要跳转的网页URL”> </form>,该传参方式是隐式的,不容易暴露;另一种方式是通过get方法提交表单数据,或页面导向通过“URL?Parameter=Value”格式传递参数值时,即使用Request对象QueryString属性获取传递过来的信息,这个传参方式一般不建议使用,因在URL之后,所以容易在浏览器暴露参数,容易遭受黑客的攻击,再者是URL的字节数有限,即传递的参数有限,所以不建议使用QueryString。
这里需要建立两个web程序页,第一个Default.aspx页中运用各种控件,第二个是在get-form.aspx的后台代码中在页面加载的时候获得Default.aspx页中,用户提交的信息数据。
Default.aspx的html代码:
view source
< id="highlighter_304109_clipboard" title="copy to clipboard" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="16" height="16" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" type="application/x-shockwave-flash">
print?
01
<PREclass=brush:csharp><%@ Page Language="C#"AutoEventWireup="true"CodeBehind="Default.aspx.cs"Inherits="form._Default"%>
02
  
03
<!DOCTYPE html PUBLIC"-//W3C//DTD XHTML 1.0 Transitional//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
04
  
05
<html xmlns="http://www.w3.org/1999/xhtml">
06
<head runat="server">
07
    <title>无标题页</title>
08
</head>
09
<body>
10
    <form. id="Form1"action="get_form.aspx"method="post">
11
    <div style="text-align:center">
12
    填写用户信息
13
    <hr  style="size:50%"/>
14
&


相关文档:

关于 ASP.NET 三层架构

一般对于用过 动软.net代码生成器的人来说,省了好多事情。  model (实体层),  dal(数据访问层),  bll(业务逻辑层)
model 就不用说了 dal数据访问层有的时候要调用存储过程,以前很少写,觉得参数的调用挺费劲的,大家有什么好的办法能提高存储过程吗!!!!!!!!!! ......

ASP.NET网站开发小结

1.<script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
Vs2005红色了,提示找不到该文件
于是改为.<script src="/Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
结果红色没有了,但是编译时报错,找不到该文件
结论:<script src="Script ......

asp.net(C#) 数据库备份还原 源码

Backup.aspx
  protected void Button1_Click(object sender, EventArgs e)
    {
        string path = Server.MapPath("") + @"\Backup";
        if (!Directory.Exists(path))
       ......

asp.net时间格式大全

DateTime dt = DateTime.Now;
// Label1.Text = dt.ToString();//2005-11-5 13:21:25
// Label2.Text = dt.ToFileTime().ToString();//127756416859912816
// Label3.Text = dt.ToFileTimeUtc().ToString();//127756704859912816
// Label4.Text = dt.ToLocalTime().ToString();//2005-11-5 21:21:25
// Label5.Text = ......

asp.net小数点四舍五入的方法

1.只要求保留N位不四舍5入
  float f = 0.55555f;int i =(int)(f * 100);f = (float)(i*1.0)/100;
  2.保留N位,四舍五入 .
  decimal d= decimal.Round(decimal.Parse("0.55555"),2);
  3.保留N位四舍五入
  Math.Round(0.55555,2)
  4,保留N位四舍五入
  double dbdata = 0.5 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号