Browser makes a request

What happens at the serverside when a browser makes a request to the server for a particular page? Explain in detail

Questions by chary_07

Showing Answers 1 - 5 of 5 Answers

when browser makes a request for a particular page then the request is sent through get method to the server(some other process occurs in between the ways .e.g: DNS mapping,etc).

Server recieves the page request at its port which is generally configurred at port:80
server then generates RENDERED code and sends it back to the browser and web page is displayed into web browser.

2nd CASE :
if page is using CASHING then server just recieves the page request and search the requested page into its cache and returns the pre-rendered code to browser thus saving the execution time overhead [:)]
so always use caching technique.
I hope this might satisfy you a little bit as i m a fresher in .NET!!!

Server first checks whether that browser belongs to ASP.NET or NOT.

If it is ASP.NET file it creates Application domain.Then,If this is first request compile with a file and executed.Else precompile version is executed.Then final HTML page is sent to the user.

If browser not  belongs to ASP.NET it is not involved.

  Was this answer useful?  Yes

pmapkiranch

  • Nov 17th, 2010
 

When browser makes a request we have HTTP handlers at server which will filter the requests and route to appropriate queue.
For instance if request is .apsx then

  • Loads corresponding xxx.aspx page,system dlls etc to process the page into the memory.
  • Executes the page and transforms to htms because browser can understand only html no matter what code behind you use ultimately it should converted to html.
  • After processing html code is buffered and sends to browser.
  • As and when browser receives html code browser has perser which will finally render html and you see the output on the page.
Many things will happen like caching etc in between but imortant stuff is above one.

  Was this answer useful?  Yes

Application life cycle:
serverside process after browser
1. Request generated by Browser
2. IIS
3. ASPNet_ISAPI.dll
4. Application Manager Creates App Domain
5. Httpruntime Objects and HttpContext object
6. HttpApplication object
7.HttpModule
8. Httphandler
9. Page
10 HttpModule
11. Response

  Was this answer useful?  Yes

Rajesh Kumar

  • Sep 8th, 2011
 

IIS recieves the request.

IIS examines the extension to know if this extention is registered with asp.net?(generally aspx, ashx, asmx)
IIS hands over asp.net requests to aspnet_isapi
Application Manager is created
HttpContext , HttpRequest, HttpResponse objects are created

Modules are in initialized (This is where modules register their own methods with HTTPApplication events)
HttpAppliction object created (in practical scenarios we have global.asax which always inherits from HttpApplication class. in those casesa an object of global.asax is created.)

various HTTPApplication events are executed (like begin_request, authenticate, authorize, resolve_cache, resolve_state, get_handler, execute_Hadler,update_cache, update_state, end_request) for the exact list of events please refer to MSDN.

execute_handler is the method which is responsible for page life cycle. We can also custome httphandlers which perform necessary action on server and writes the output in the HTTPResponse object.

the response goes through the remaining events of HttpApplication and can be tampered with using modules registered with those events.

finally, the httprespoonse is sent back.

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions