state managment
Upcoming SlideShare
Loading in...5
×
 

state managment

on

  • 1,387 views

 

Statistics

Views

Total Views
1,387
Views on SlideShare
1,387
Embed Views
0

Actions

Likes
1
Downloads
20
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

state managment state managment Presentation Transcript

  • State Management Anil Kumar Yadav
  • TYPES OF STATE MANAGEMENT
    • Client-Side State Management.
    • Server-Side State Management.
  • Client- Side State Management
    • View State.
    • Hidden field.
    • Cookies.
    • Query strings.
    • Control State.
    View slide
  • View state
    • ASP .Net mechanism to persist data through server round trips on a single page.
    • Web Forms pages provide the view state property as a built-in structure for automatically retaining values between multiple requests for the same page. View state is maintained as a hidden field in the page.
    • Benefits and Limitation :
    • No server resources are required because state is in a structure in the page code.
    • Simplicity.
    • States are retained automatically.
    • View state is good for caching data in Web frame configurations because the data is cached on the client.
    View slide
  • The View State property:
    • Retains values between multiple requests for the same page.
    • ASP. Net mechanism to persist data through server round trips on a single page.
    • You can add your own data to view state using :View State[“Price”]==price;
    • decimal price=(decimal)View State[“Price”];
  • What are benefits and Limitation of using Hidden fields ?
    • Following are the benefits of using Hidden fields :
    • They are simple to implement.
    • As data is cached on client side they work with Web Farms.
    • All browsers support hidden field.
    • No server resources are required.
    • No effect on security level setting in browsers.
    • NOTE: You can use a hidden field only on pages that are submitted to the server.
  • Cookies
    • A cookie , also known as an HTTP cookie , web cookie , or browser cookie , is used for an origin website to send state information to a user's browser and for the browser to return the state information to the origin site.
    • Cookies store data in the browser .
    • A cookie , also known as an HTTP cookie , web cookie , or browser cookie , is used for an origin website to send state information to a user's browser and for the browser to return the state information to the origin site. [
  • 1. S ize and number of cookies stored are limited. 2. It stored as plain-text in a specific directory, everyone can view and modify them. Personal information is exposed. 3. I t won't work if the security level set too high in browser. Disadvantages
  • Query Strings A query string is information appended to the end of a page's URL. Note: You can use query strings only if you are requesting the same page, or another page via a link.
  • Benefits of using query string for state Management:-
    • No server resources are required. The query string containing in the HTTP requests for a specific URL.
    • All browsers support query strings.
  •