• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

how to handle browser back button in jsf application

 
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i am using richfaces3 in my web application. the problem I'm facing here is.. if the user has visited some other site like Google.com and visits my application, logs into my application, he is redirected to home page. Now if the user clicks back button he will be redirected to the previous page that is Google.com. And if the user clicks the forward button the user is directly taken to home page, without asking him to login. I am not changing the URL my app even if i am redirecting to other pages in my application. I want to force the user to login in this scenario. how can this be achieved ? please give me your suggestions.
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Goes to the homepage because the user still has an active session. There is no way to kill the session when the user goes to another site.

Eric
 
rashmi coorg
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
if we can capture the event when browser back button is clicked.. may be we can kill the session on occurrence of that event.. can you suggest me if this can be done.. and if it can be done.. how can we capture the event?
 
Ranch Hand
Posts: 672
4
Eclipse IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

rashmi coorg wrote:if we can capture the event when browser back button is clicked.. may be we can kill the session on occurrence of that event..


Say, user logs in, goes to home page and goes to some other page, in the same application, now if (s)he clicks back, what happens?
 
rashmi coorg
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Prasad Krishnegowda wrote:
Say, user logs in, goes to home page and goes to some other page, in the same application, now if (s)he clicks back, what happens?




Within my application the back button is disabled. But when i navigate outside my application. i am facing this problem. The url of the app doesnot change when i navigate from one page to another within the application.
Any suggestions..??
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic