ASP.NET

ASP.NET is widely used to create websites.

ASP.NET Page Life Cycle:-

1)Page Pre_Init
   Initializes Themes and Skins.

2)Page Init
   Initializes Controls.

3)Page Load
Loads web page into main memory

4) Page Control Events
Initializes Control Events like Mouse Click, dropdown Selected index change.

5)Page Pre_Render
This is last chance you can edit your webpage.

6) Page Render
This is process of Showing Output to browser.

7)Page Unload
Web Page is copied into cache memory when life cycle is completed and it is deleted from main memory.


 What is Query String? What are its advantages and limitations?

The Query String helps in sending the page information to the server.

The Query String has the following advantages:

  • Every browser works with Query Strings.
  • It does not require server resources and so does not exert any kind of burden on the server.

The following are the limitations of Query String:
  • Information must be within the limit because URL does not support many characters.
  • Information is clearly visible to the user, which leads to security threats.

What is ViewState?

The ViewState is a feature used by ASP.NET Web page to store the value of a page and its controls just before posting the page. Once the page is posted, the first task by the page processing is to restore the ViewState to get the values of the controls.

Explain how Cookies work. Give an example of Cookie abuse.

The server tells the browser to put some files in a cookie, and the client then sends all the cookies for the domain in each request. An example of cookie abuse is large cookies affecting the network traffic.

ViewState persist the values of controls of particular page in the client (browser) when post back operation done. When user requests another page previous page data no longer available.

SessionState persist the data of particular user in the server. This data available till user close the browser or session time completes.


 

No comments:

Post a Comment