How to get referring URL

I was hoping to find a function like request.getReferrer(), but according to my books there is no such thing(****)Is there any way to get the URL of the page you just came from, I need it in case I need to send you away, back from whence you came kind of thing...?
[292 byte] By [wmacey] at [2007-9-26 1:32:13]
# 1

I think I saw this answered somewhere else, but I'll go ahead and answer it again here.

The method you need is request.getHeader(String); call this with the keyword "Referer" and it will get you the info you need:String ref = "" + request.getHeader("Referer");

cafal at 2007-6-29 1:32:55 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
try...<%@page language="java" import="javax.servlet.http.HttpUtils" %><% out.println(HttpUtils.getRequestURL(request).substring(0)+((request.getQueryString()!=null)?"?"+request.getQueryString():"")); %>
rgoliveira at 2007-6-29 1:32:55 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3
ops, Im sorry wrong place. ;)
rgoliveira at 2007-6-29 1:32:55 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...