File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Servlets and the fly likes How do I get the last page served up? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "How do I get the last page served up?" Watch "How do I get the last page served up?" New topic
Author

How do I get the last page served up?

Dale DeMott
Ranch Hand

Joined: Nov 02, 2000
Posts: 515
How do I get the last page that was served up from the Servlet? Is this possible?


By failing to prepare, you are preparing to fail.<br />Benjamin Franklin (1706 - 1790)
K Riaz
Ranch Hand

Joined: Jan 08, 2005
Posts: 375
You should store the name of the last page in a session variable.
Dale DeMott
Ranch Hand

Joined: Nov 02, 2000
Posts: 515
I could.. but is there a way to get the page out of the response?
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

If the user got to the current page by clicking on a link, the browser will send up a header named 'Referer' [correct spelling].

So will return it. If they've come to your page by typing the address directly or from a bookmark in the browser, the value will be null.


Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How do I get the last page served up?
 
Similar Threads
creating servlet
Restict GET method access for an action url - Struts
Java FileUploading
disadvantages of AJAX - Explanation required
jsp:include throws Exception