Hi Betty,
Actually, I *do* think that this information is available as part of a
normal HTTP request
(at least under some conditions, like if redirected by a page whose status
code is
"temporarily moved" or "permanently moved").
I have vague memories of using this feature from CGI about 4 years ago....
I think that if you use request.getHeaderNames() and print out the results,
you may find
the header name you want, eg it might be "http-referrer". Once you figure
out what
the header you need is, you can then use request.getHeader("http-referrer")
or whatever
in your code.
You might also want to search around on www.w3c.org for the actual formal
definition.
Of course I could be completely wrong..
Cheers,
Simon
> -----Original Message-----
> From: Chris Freyer [SMTP:[EMAIL PROTECTED]]
> Sent: Thursday, November 09, 2000 4:10 PM
> To: '[EMAIL PROTECTED]'
> Subject: RE: servlets and the refer link
>
> I'm not aware of any call to get the most recent page from a browser's
> cache. It isn't sent as part of a normal HTTP request.
> You can get it using javascript though--create an HTML or JSP page that
> contains a hidden form. Place a JavaSript function in the page that runs
> in the OnLoad event. Make it detect the browser and use the correct
> object model to grab the most recent entry in the history list and put it
> in the form. Then submit the form to your server.
>
> Fair warning though--people don't like it when developers mess with their
> privacy. Be careful.
>
> Chris
>
> -----Original Message-----
> From: Betty Chang [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, November 08, 2000 11:07 PM
> To: [EMAIL PROTECTED]
> Subject: servlets and the refer link
>
>
>
> Hi all -- which call do I make to obtain the "refer link" when my
> servlet is accessed via a doGet()?
>
> I want to obtain the last URL that user visited before getting to my
> servlet. Is that possible?
>
> Thanks
>
> Betty
>
>