Hello friends,
Here is some explanation for hows the request from browser to web server is handled by Asp,Net..
Very first and in basic Browser sends the request will proceed in two steps:
1) Browser sends the request to your webserver [e.g IIS..].. 2) Webserver will identify your web page type and forward to appropriate DLL or Engine..like if page type is .aspx than it will pass to process to the its appropriate engine..
Now lets see hows internally this request has been handled:
As for example we are taking ASPX page to handle at web server IIS.
Once IIS passes the request to ASP.NET engine page has to go through two section HTTP module and HTTP handler. Both these section have there own work to be done in order that the page is properly compiled and sent to the IIS.Both work as follow to complete the Request cycle of web page.
HTTP modules watch/inspect the incoming request and depending on that they can pass/forward to appropriate way to handle it. Authentication of page is also handle in this section only..
HTTP handler actually compiles the page and generates output.
If you see your machine.config file you will see following section of HTTP modules.
< httpModules> < add name="OutputCache" type="System.Web.Caching.OutputCacheModule" /> < add name="Session" type="System.Web.SessionState.SessionStateModule" /> < add name="WindowsAuthentication" type="System.Web.Security.WindowsAuthenticationModule" /> < add name="FormsAuthentication" type="System.Web.Security.FormsAuthenticationModule" /> < add name="PassportAuthentication" type="System.Web.Security.PassportAuthenticationModule" /> < add name="UrlAuthorization" type="System.Web.Security.UrlAuthorizationModule" /> < add name="FileAuthorization" type="System.Web.Security.FileAuthorizationModule" /> < add name="ErrorHandlerModule" type="System.Web.Mobile.ErrorHandlerModule, System.Web.Mobile, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /> </httpModules>
Ok now the HTTP handler is where the actual compilation takes place and the output is generated.Following is a paste from HTTP handler section of WEB.CONFIG file.
< httpHandlers> < add verb="*" path="*.jsl" type="System.Web.HttpForbiddenHandler" /> < add verb="*" path="trace.axd" type="System.Web.Handlers.TraceHandler" /> < add verb="*" path="*.aspx" type="System.Web.UI.PageHandlerFactory" /> < add verb="*" path="*.ashx" type="System.Web.UI.SimpleHandlerFactory" /> </httpHandlers>
Once the file is compiled it send back again to the HTTP modules and from there to IIS and then to the browser.
With Regards..
Ashish Shah India
|
| Author: Trupti 30 Jul 2008 | Member Level: Silver Points : 0 |
Really a gre88888 article with easy explanation.
|
| Author: Ashish Shah 31 Jul 2008 | Member Level: Gold Points : 1 |
Ohh thankx for your kindly comment..
With Regards..
Ashish shah India,surat
|