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

ASP.NET post·ÃÎÊÍâÍø½Ó¿Ú»ñÈ¡Êý¾Ý

·½·¨Ò»£º
 string postData = string.Format("a=1&b=2");   //post´«µÝ²ÎÊý
        Stream outstream = null;
        Stream instream = null;
        StreamReader sr = null;
        HttpWebResponse response = null;
        HttpWebRequest request = null;
        Encoding encoding = Encoding.Default;
        byte[] data = encoding.GetBytes(postData);
        // ×¼±¸ÇëÇó
       
            // ÉèÖòÎÊý
            request = WebRequest.Create("http://www.baidu.com") as HttpWebRequest;
            CookieContainer cookieContainer = new CookieContainer();
            request.CookieContainer = cookieContainer;
            request.AllowAutoRedirect = true;
            request.Method = "POST";
            request.ContentType = "application/x-www-form-urlencoded";
            request.ContentLength = data.Length;
            outstream = request.GetRequestStream();
            outstream.Write(data, 0, data.Length);
            outstream.Close();
            //·¢ËÍÇëÇó²¢»ñÈ¡ÏàÓ¦»ØÓ¦Êý¾Ý


Ïà¹ØÎĵµ£º

ÅäÖÃASP.netÔËÐÐÈÕÖ¾

ÎÒÖ÷ÒªÓÃÀ´¸ú×Ùºǫ́µÄһЩÇé¿ö£¬ÎÒÓõÄÊÇÒ»¸öµÚÈý·½²å¼þ£¬ºÜºÃÓõÄ
log4net
¾ßÌåʹÓÃÈçÏ£º
Web.configÅäÖãº
<configSections>
    <section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net"/>
</configSections>
<log4net>
 &nbs ......

ÔËÐÐ ASP.NET µÄ½ø³ÌÕÊ»§±ØÐë¾ßÓÐIIS ÔªÊý¾Ý¿âȨÏÞ

ÎÊÌâ:
ÓÃÓÚÔËÐÐ ASP.NET µÄ½ø³ÌÕÊ»§±ØÐë¾ßÓÐ¶Ô IIS ÔªÊý¾Ý¿â(Èç IIS://servername/W3SVC)µÄ¶Á·ÃÎÊȨ¡£
³öÏÖ´ËÎÊÌâ¶àÊÇÒòΪÏÈ×°.net frameworkºó×°IIS Ôì³É
½â¾ö·½·¨:
¿ªÊ¼->³ÌÐò->Microsoft .NET Framework SDK v2.0->SDK ÃüÁîÌáʾ
ÊäÈë
aspnet_regiis   -i  »Ø³µ
---OVER--- ......

asp.net ÈçºÎʵÏÖÓÊÏäÑéÖ¤

Ê×ÏÈÊý¾Ý¿â±íµÄÉè¼Æµ±ÖÐ
×¢²áÓû§±íÓ¦¸Ã°üº¬Ò»¸öÊÇ·ñ¼¤»îµÄ×ֶΣ¬Í¨¹ý´Ë×Ö¶ÎÀ´ÅжÏÊÇ·ñ¼¤»î¡£ºÍÒ»¸ö¼¤»îkeyµÄ×ֶΣ¬´Ë×Ö¶ÎÓÃÓÚ·ÅÖü¤»îÂë
³ÌÐò·½Ãæ
ÔÚÓû§×¢²áµÄʱºòËæ»úÉú³ÉÒ»¸ö¼¤»îÂë(ÇëÈ·±£¼¤»îÂëΨһ)£¬°ÑÓû§ÐÅÏ¢¼°¼¤»îÂë²åÈëµ½Êý¾Ý±íÖС£
ͨ¹ý·¢ÓʼþµÄ·½Ê½Ïò×¢²áÓû§ÌṩµÄÓÊÏä·¢Ò»·â°üº¬¼¤»îÁ´½ÓºÍ¸Õ¸ÕÉú³ÉµÄ¼¤» ......

ASP.NETÖзÀÖ¹Ò³Ãæ¶à´ÎÌá½»µÄ´úÂë

javascript< script language="javascript"> < !-- function disableOtherSubmit() {
var obj = event.srcElement;
var objs = document.getElementsByTagName('INPUT');
for(var i=0; i< objs.length; i++)
{
if(objs[i].type.toLowerCase() == 'submit')
{
objs[i].disabled = true;
}
} ......

ASP.NETÒ³Ãæˢз½·¨×ܽá

private void Button1_Click( object sender, System.EventArgs e ) { Response.Redirect( Request.Url.ToString( ) ); } µÚ¶þ£º
private void Button2_Click( object sender, System.EventArgs e ) { Response.Write( " < script language=javascript>window.location.href=document.URL; < /script>" ); } ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ