[Zope] Re: Getting the full URL of the REQUEST.
Maik Jablonski
maik.jablonski@uni-bielefeld.de
Wed, 28 May 2003 19:41:18 +0200
Gilles Lenfant wrote:
> Hi,
>
> Is there a simple way to get the *full* URL (the one shown in the browser,
> including the query)
>
> REQUEST.URL stops before that query.
A simple PythonScript should do the job:
URL = context.REQUEST.get('URL')
QUERY_STRING = context.REQUEST.get('QUERY_STRING')
if QUERY_STRING:
return "%s?%s" % (URL, QUERY_STRING)
else:
return URL
Cheers, Maik