[Zope] Site Access Rule/Request URL

Dieter Maurer dieter at handshake.de
Wed Jun 9 15:14:19 EDT 2004


Bruno Silva wrote at 2004-6-9 15:22 +0100:
>    I have a folder with a site access rule, and i want to know the URL
>of the request, but the "context.REQUEST['URL0']" only have the url of
>the folder where the site access rule is, and not the complete request.
>Can anyone help me?

Two options:

  * You find the missing parts in "REQUEST.TraversalRequestNameStack"
    (or similar). This is a list of names still to visit
    in reverse order (i.e. the last name is the next to visit).

  * "REQUEST.PATH_INFO" contains the original request URL.
    This is not necessary the one that Zope actually traverses,
    as (e.g.) it can contain VHM instructions or do not contain
    elements added by ":method|action" parameter directives.

-- 
Dieter



More information about the Zope mailing list