Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How force refresh of page from object called by jsp/servlet?

 
Dan Bizman
Ranch Hand
Posts: 387
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How (and what's the best way to) do I force a refresh of a page/the browser from inside an object that's called? Can I do it if the object only has a Session object? or does it need the response object (to set headers)? Is there another waay to do it?

Here's what i have:

JSP reads a parameter "logout" and pulls an object from the Session "LoginHandler". It then calls "logout()" on it.

Now what I'd prefer is that the JSP only call logout() and the page kicks them out to a login page. But I'm guessing I'd have to either find a way to pass the response object to the LoginHandler or have the JSP set the refresh header (or change the date) itself. Is there a way I'm missing?
[ October 25, 2006: Message edited by: Dan Bizman ]
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64858
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm confused about your terminology.

When you say "refresh" are you really meaning "redirect"?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic