´ÓASP.NETÓ¦ÓóÌÐòÉú´æÖÜÆÚ̸Æð(2)
ÄÇôͨ¹ýÒÔÉϵÄ˵Ã÷£¬ÎÊÌâ¶þ£ºÎÒÃÇÔõô֪µÀIISºÍASP.NET ISAPIµ½µ×ÊÇÔõÑù¹¤×÷µÄ£¿
ASP.NET Process ModelÖ®Ò»£ºIIS ºÍ ASP.NET ISAPI
Ç°¼¸ÌìÓÐÒ»¸öÅóÓÑÔÚMSNÉÏÎÊÎÒ“ASP.NET ´Ó×î³õµÄ½ÓÊÕµ½Http requestµ½×îÖÕÉú³ÉResponseµÄÕû¸öÁ÷³Ìµ½µ×ÊÇÔõÑùµÄ£¿”ÎÒ¾õµÃÕâ¸öÎÊÌâÉæ¼°µ½IISºÍASP.NETASP.NET RuntimeµÄ´¦ÀíÄ£Ð͵ÄÎÊÌ⣬²¢²»ÊÇÈýÑÔÁ½Óï¾ÍÄÜ˵Çå³þµÄ£¬ËùÒÔ¾ö¶¨Ð´ÕâÑùһƪ½éÉÜIISºÍASP.NET Runtime Process ModelµÄÎÄÕ£¬Ì¸Ì¸ÎҶԴ˵ÄÒ»¸ö´ÖdzµÄÈÏʶ£¬Èç¹ûÓÐʲô²»¶ÔµÄµØ·½£¬Ï£Íû´ó¼Ò¼°Ê±Ö¸Õý¡£
ÕâƪÎÄÕ´óÌå·ÖΪÁ½¸ö²¿·Ö£¬µÚÒ»²¿·ÖÎÒ½«Ì¸Ì¸IISµÄÁ½¸ö²»Í¬µÄ°æ±¾—IIS 5.x ºÍ IIS 6£¨ËäÈ»IIS 7ÒѾReleaseºÜ³¤Ê±¼äÁË£¬¶øÇÒ½Ï֮ǰÁ½¸ö°æ±¾·¢ÉúÁ˷dz£´óµÄ±ä»¯£¬ÓÉÓÚ±¾ÈËȱ·¦¶ÔIIS 7ÉîÈëµÄÁ˽⣬ËùÒÔÔÚÕâÀï¾Í²»ÔÙ½éÉÜÁË£¬²»¹ýÒÔºóÎÒ½«Õâ·½ÃæµÄÄÚÈݲ¹ÉÏ£©µÄ´¦ÀíÄ£ÐÍ£ºIISÈçºÎ¼àÌýÀ´×ÔÍâ½çµÄHttp request£¬ÈçºÎ¸ù¾ÝISAPI Extension Mapping½«¶ÔÓÚ²»Í¬ResourceµÄÇëÇó·Ö·¢¸ø²»Í¬µÄISAPI Extension£¬»ùÓÚASP.NET ResourceµÄASP.NET ISAPIÈçºÎ½«Request´«µÝ¸øASP.NET Runtime »·¾³¡£µÚ¶þ²¿·Ö½«×ÅÖؽéÉÜÔÚÒ»¸öÍйܵÄASP.NET Runtime »·¾³¶Ô´«ÈëµÄHttp requestµÄ´¦Àí¹ý³Ì¡£ÎÒÃÇÏÈÀ´¿´¿´IIS 5.xºÍIIS 6µÄ´¦Àí¹ý³Ì¡£
1£® Ò»¡¢IIS 5.x based Process Model
IIS 5.xÒ»¸öÏÔÖøµÄÌØÕ÷¾ÍÊÇWeb ServerºÍÕæÕýµÄASP.NET ApplicationµÄ·ÖÀë¡£×÷ΪWeb ServerµÄIISÔËÐÐÔÚÒ»¸öÃûΪInetInfo.exeµÄ½ø³ÌÉÏ£¬InetInfo.exeÊÇÒ»¸öNative Executive£¬²¢²»ÊÇÒ»¸öÍйܵijÌÐò£¬¶øÎÒÃÇÕæÕýµÄASP.NET ApplicationÔòÊÇÔËÐÐÔÚÒ»¸ö½Ð×öaspnet_wpµÄWorker ProcessÉÏÃ棬Ôڸýø³Ì³õʼ»¯µÄʱºò»á¼ÓÔØCLR£¬ËùÒÔÕâÊÇÒ»¸öÍйܵĻ·¾³¡£ÎÒÃǽÓÏÂÀ´½«Ì¸ÂÛaspnet_wpÈçºÎ´´½¨£¬aspnet_wpºÍInetInfo.exeÈçºÎ½øÐÐͨÐÅ£¬ÒÔ¼°¼òµ¥½éÉÜÔÚaspnet_wpÖУ¬ÈçºÎ½«Request µ¼ÈëASP.NET Rutime Pipeline¡£
ÎÒÃÇͨ¹ý´´½¨ÐéÄâĿ¼½«×ÊÔ´Hostµ½IISÏ£¬ÔÔòÉÏ£¬ÎÒÃÇ¿ÉÒÔͨ¹ýIIS·ÃÎÊÖÃÓÚÐéÄâĿ¼ÏµÄËùÓÐResource£¬Õⲿ½ö½ö°üº¬Ò»Ð©¾²Ì¬×ÊÔ´Îļþ£¬±ÈÈçͼƬ¡¢´¿HtmlÎļþ¡¢CSS¡¢JSµÈµÈ£¬Ò²°üº¬Ò»Ð©ÐèÒª¶¯Ì¬Ö´ÐеÄÎļþ£¬±ÈÈçaspx£¬asmxµÈµÈ£¬ÎÒÃÇ»¹¿ÉÒÔ½«RemotingºÍWCF Service Hostµ½IISÏ¡£¶ÔÓÚÕâЩ¾²Ì¬µÄÎļþ£¬IISÖ±½ÓÌáÈ¡¶ÔÓ¦µÄÎļþ½«Æä×÷ΪHttp Response·µ»Ø¸øClient£¬µ«ÊǶÔÓ
Ïà¹ØÎĵµ£º
ÔÚWeb±à³Ì¹ý³ÌÖУ¬´æÔÚןܶలȫÒþ»¼¡£±ÈÈçÔÚÒÔÇ°µÄASP°æ±¾ÖУ¬CookieΪ·ÃÎÊÕߺͱà³ÌÕ߶¼ÌṩÁË·½±ã£¬²¢Ã»ÓÐÌṩ¼ÓÃܵŦÄÜ¡£´ò¿ªIEä¯ÀÀÆ÷£¬Ñ¡Ôñ“¹¤¾ß”²Ëµ¥ÀïµÄ“InternetÑ¡Ï¬È»ºóÔÚµ¯³öµÄ¶Ô»°¿òÀïµ¥»÷“ÉèÖÔ°´Å¥£¬Ñ¡Ôñ“²é¿´Îļþ”°´Å¥£¬ÔÚµ¯³öµÄ´°¿ÚÖУ¬¾Í»áÏÔʾӲÅÌÀï ......
ÎÊÌâ:
ÓÃÓÚÔËÐÐ ASP.NET µÄ½ø³ÌÕÊ»§±ØÐë¾ßÓÐ¶Ô IIS ÔªÊý¾Ý¿â(Èç IIS://servername/W3SVC)µÄ¶Á·ÃÎÊȨ¡£
³öÏÖ´ËÎÊÌâ¶àÊÇÒòΪÏÈ×°.net frameworkºó×°IIS Ôì³É
½â¾ö·½·¨:
¿ªÊ¼->³ÌÐò->Microsoft .NET Framework SDK v2.0->SDK ÃüÁîÌáʾ
ÊäÈë
aspnet_regiis -i »Ø³µ
---OVER--- ......
0.ÓÃsessionÅжÏÊÇ·ñµÇ½
if(Session["login"] == null)
{
Response.Redirect("error.aspx");
}
1. ´ò¿ªÐµĴ°¿Ú²¢´«ËͲÎÊý£º
´«ËͲÎÊý£º
response.write("<script>window.open('*.aspx?id="+this.DropDownList1.SelectIndex+"&id1="+...+"')</s ......
ǰ̨´úÂë
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width='<%=focus_width %>' height='<%=swf_height %>'>
<pa ......
asp.net ÍøÒ³´«²ÎµÄ¼¸ÖÖ³£Ó÷½Ê½
µÚÒ»ÖÖ£ºQueryString
//½«Ô´Ò³Ãæstart.aspxÖеÄlable ºÍtextboxÖеÄÄÚÈÝ´«µ½end.aspxÒ³ÃæÖÐ ²¢ÔÚÆälable ºÍtextboxÖÐÏÔʾ´«¹ýÀ´µÄÄÚÈÝ
Ô´Ò³Ãæ´úÂ룺
protected void Button1_Click(object sender, EventArgs e)
{
& ......