• Post Reply Bookmark Topic Watch Topic
  • New Topic

Track previous page

 
chris freeborn
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Suppose, you are on a jsp page.
How can you get the url of the page you came from before you reached this page?
Is there something in the request object or something that can help?
Thanks
 
danny liu
Ranch Hand
Posts: 185
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
a. URL rewriting, add sth like pageid=9.
b. add an attribute in session,
e.g., session.addAttribute("previousPage",new Integer(9));
c. use cookie
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65520
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You might try the "referer" request header. It may contain what you are after.
[ January 27, 2004: Message edited by: Bear Bibeault ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!