Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

asp.net»ñÈ¡´«ÖµgetºÍpostÇëÇó

//postÇëÇó
string name = Request["name"].toString();
string name =Request.Form.Get("name").toString();
//getÇëÇó
string name = Request.QueryString["name"].toString();
µ«ÎÒ·¢ÏÖ ÎÞÂÛÊÇ·ñÊÇpostÓëget´«Öµ¶¼¿ÉÓÃ
string name = Request["name"].toString();

±íµ¥Ìá½»ÖÐgetºÍpost·½Ê½µÄÇø±ð¹éÄÉÈçϼ¸µã£º
1. getÊÇ´Ó·þÎñÆ÷ÉÏ»ñÈ¡Êý¾Ý£¬postÊÇÏò·þÎñÆ÷´«ËÍÊý¾Ý¡£
2. getÊǰѲÎÊýÊý¾Ý¶ÓÁмӵ½Ìá½»±íµ¥µÄACTIONÊôÐÔËùÖ¸µÄURLÖУ¬ÖµºÍ±íµ¥ÄÚ¸÷¸ö×Ö¶ÎÒ»Ò»¶ÔÓ¦£¬ÔÚURLÖпÉÒÔ¿´µ½¡£postÊÇͨ¹ýHTTP post»úÖÆ£¬½«±íµ¥ÄÚ¸÷¸ö×Ö¶ÎÓëÆäÄÚÈÝ·ÅÖÃÔÚHTML HEADERÄÚÒ»Æð´«Ë͵½ACTIONÊôÐÔËùÖ¸µÄURLµØÖ·¡£Óû§¿´²»µ½Õâ¸ö¹ý³Ì¡£
3. ¶ÔÓÚget·½Ê½£¬·þÎñÆ÷¶ËÓÃRequest.QueryString»ñÈ¡±äÁ¿µÄÖµ£¬¶ÔÓÚpost·½Ê½£¬·þÎñÆ÷¶ËÓÃRequest.Form»ñÈ¡Ìá½»µÄÊý¾Ý¡£
4. get´«Ë͵ÄÊý¾ÝÁ¿½ÏС£¬²»ÄÜ´óÓÚ2KB¡£post´«Ë͵ÄÊý¾ÝÁ¿½Ï´ó£¬Ò»°ã±»Ä¬ÈÏΪ²»ÊÜÏÞÖÆ¡£µ«ÀíÂÛÉÏ£¬IIS4ÖÐ×î´óÁ¿Îª80KB£¬IIS5ÖÐΪ100KB¡£
5. get°²È«ÐԷdz£µÍ£¬post°²È«ÐԽϸߡ£


Ïà¹ØÎĵµ£º

ASP.NETÑéÖ¤¿Ø¼þÏê½â

¹ã¶«ÄϺ£Êй«°²¾Ö¼ÆËã»ú°²È«¼à²ì¹ÉÓ÷¿­
    ASP.NETÊÇ΢ÈíÍÆ³öµÄÏÂÒ»´úWEB¿ª·¢¹¤¾ß£¬ÆäÇ¿´óµÄ¹¦ÄÜÁ¢¼´ÎüÒýÁËÒ»´óÅúWEB¿ª·¢ÕßͶÈëËüµÄÃÒÏ¡£ÏÖÔÚ£¬ÎÒÃÇÀ´¿´¿´ASP.NETµÄÑéÖ¤¿Ø¼þ£¬¸ÐÊÜASP.NETµÄÇ¿´ó¹¦ÄÜͬʱ·½±ãÎÒÃÇÏÖÔÚµÄWEB¿ª·¢¡£
WEB¿ª·¢ÕßÌØ±ðÊÇASP¿ª·¢Õߣ¬Ò»Ö±¶ÔÊý¾ÝÑéÖ¤±È½ÏÄջ𣬵±ÄãºÃ²»ÈÝÒ×д³öÊý¾ ......

asp.net Óʼþ·¢ËÍ

//ʵÀý»¯Ò»¸öSmtpClientsmtp.DeliveryMethod = SmtpDeliveryMethod.Network;
SmtpClient smtp = new SmtpClient();
smtp.DeliveryMethod = SmtpDeliveryMethod.Network;

//½«smtpµÄ³öÕ¾·½Ê½ÉèΪ Networksmtp.EnableSsl = false;
//smtp·þÎñÆ÷ÊÇ·ñÆôÓÃSSL¼ÓÃÜ
smtp ......

ASP.NET´¦Àí³ÌÐòºÍÄ£¿é£¨Ò»£©

ASP.NET´¦Àí³ÌÐòºÍÄ£¿é
          
          ASP.NET HTTP ´¦Àí³ÌÐò(Handler)ÊÇÏìÓ¦¶Ô ASP.NET Web Ó¦ÓóÌÐòµÄÇëÇó¶øÔËÐеijÌÐò
          
          Èç´¦Àí *.aspxÎļþµÄASP.NET´¦Àí³ÌÐò ......

asp.net³£Óü¼ÇÉ

´ò¿ªÐµĴ°¿Ú²¢´«ËͲÎÊý£º
´«ËͲÎÊý£º
response.write("<script>window.open('*.aspx?id="+this.DropDownList1.SelectIndex+"&id1="++"')
</script>")
½ÓÊÕ²ÎÊý£º
string a = Request.QueryString("id");
string b = Request.QueryString("id1");
2.Ϊ°´Å¥Ìí¼Ó¶Ô»°¿ò
Button1.Attributes.Add("oncl ......

½â¾öasp.netÒ³Ãæ²åÈëÊý¾ÝʱȨÏÞ²»×ãÎÊÌâ

static void Main(string[] args)
  {
  string connstr = "Data Source=***;user=system;password=***;";
  OracleConnection conn = new OracleConnection(connstr);
  conn.Open();
  string orclstr="insert into SYS.A_MODULE values('03','²é¿´Éú²úÈÎÎñ','²é¿´Éú²úÈÎÎñ½ø¶È')";
  ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ