• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Session refresh

 
Ashok Nettem
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i got a problem can any one help me.I am using Session to store the information.i am using the META TAG to refresh and the session is also getting refreshed can any one help me how to retain the information the information of the session

Thanks in advance

[Topic fixed by Dave. Please don't shout]
[ February 08, 2008: Message edited by: David O'Meara ]
 
suri jagadish
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
what do you mean by session refresh. when you refresh the page it submits to the same session but the same information is sent to the server. The solution to this is the page that you are trying to display should be displayed using the response.sendRedirect() instead of request.getRequestDispacther().forward() so that when there is a refresh it will only ask for that page without submitting any data.

Hope iam clear. if you can provide me with how you are navigating then i will be able to explain in more detail.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64959
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A browser refresh will have no effect on the session unless it triggers some of your code that invalidates the session. Do you have any such code?
 
Scott Duncan
Ranch Hand
Posts: 365
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
response.sendRedirect() instead of request.getRequestDispacther().forward()


Umm, I am not really clear how either one of these calls effect the session. Please explain.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64959
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Scott Duncan:
Umm, I am not really clear how either one of these calls effect the session. Please explain.

They don't.

The OP may be confused regarding the difference between request and session scopes.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic