I'm not sure I exactly understand your requirement Heinz, but a couple of
times now I have used the java.util.Stack class to stored a LIFO queue of
visited pages.  This is maintained in the application's controlling servlet
and stored at the session scope.  The controlling servlet understands a
special web action "back", which forwards to the previous page by poping it
off the Stack.

I have used this mechanism to control "wizard" style interactions, where the
user is presented with a dynamic sequence of pages that they can traverse
back and forward through to eventually complete some sort of system
transaction.  Seems to work ok, with a bit more work I think it could be
abstracted out into a generic "wizard controller" class.

Regard

Drew Cox

> -----Original Message-----
> From: Heinz Wehner [SMTP:[EMAIL PROTECTED]]
> Sent: Sunday, January 30, 2000 8:23 AM
> To:   [EMAIL PROTECTED]
> Subject:      Tracking visited pages
>
> A common task to solve is navigating a hierarchy. Now how
> should this be implemented if every page is dynamically
> generated by a servlet?
>
> If the client's browser cache and JavaScript capabilities
> should not be used, we need some mechanism to remember the
> visited pages on the server. This may be done by using URL
> rewriting to enumerate already visited pages. The session
> object seems to be the right container.
>
> Is this a feasable approach? Are there other solutions?
>
> Heinz Wehner
> (Karlsruhe, Germany)
>
> __________________________________________________________________________
> _
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the
> body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to