Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

scopes in the jsp

 
ajay verma
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i know the 4 scopes: page,request,session,application
but what is the usage of scope in jsp?
in every technologies and frame works some scopes are defined .but how they works?
pls explain it!

thank you
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The scope of a variable determines how long it will last and who can access it. Binding a variable to context scope will cause it to last the lifetime of the application and make it available to everyone. Binding it to session will make it available only to the user who owns the session and only for the length of that session. Request scope keeps a variable alive for one request/response cycle and allows it to be accessed by different components within that cycle. Page scoped values are gone as soon as context is moved to another resource.
 
ajay verma
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks Ben Souther
thanks a lot
i am sure that you can answer my next question also

thanks again
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic