File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes HTML, CSS and JavaScript and the fly likes Click on back button problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Click on back button problem" Watch "Click on back button problem" New topic

Click on back button problem

JayaSiji Gopal
Ranch Hand

Joined: Sep 27, 2004
Posts: 303
I have a jsp page, with two links:

Back - On this link, i have the history.back(-1) function.

If a user clicks on 'Help' and then clicks on 'Back', the control goes back to the Help page, instead of the previous jsp page.

Requirement is If the user clicks on 'Back', after clicking on 'Help', how can i clear the help page from the memory, to take the user back to the previous jsp page.

Any ideas!

SCJP 1.4, SCWCD 1.4<br /> <br />Thanks in advance!<br />Jayashree.
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63858

Rather than relying on hacks like history.back, your web app should create true links with complete URLs for all navigable items.

[Asking smart questions] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: Click on back button problem
It's not a secret anymore!