[Zope-CMF] Re: Current action and action aliases

Yuppie schubbe at web.de
Fri Oct 10 15:50:23 EDT 2003


Hi!


Dieter Maurer wrote:

> Yuppie wrote at 2003-10-10 10:33 +0200:
>  > ...
>  > Actions are absolute URLs.
> 
> Are they? Most of our actions are relative URLs and many have
> a query string.

Ok. I have to relativise this. In CMFDefault they are absolute URLs. 
They don't have to be absolute URLs. But it makes it much easier to 
allow relative URLs in content if Actions are absolute URLs.

Regarding queries it would be in fact nice if REQUEST would have a key 
that returns the URL including queries.

>  > The current page is requested by an absolute 
>  > URL. So I think in theory the simplest and best solution would be to 
>  > compare URLs. If they are identical, the Action is the current Action.
> 
> Not sure about this...

Why not? (given we care also about the queries and maybe anchors)

>  > Thinking about this, I'm afraid there is a general problem with the 
>  > Method Aliases implementation. REQUEST's URL, URLx and BASEx show the 
>  > modified URL. Regarding default views this breaks backwards 
>  > compatibility and I'm not sure what REQUEST['URL'] should show: The 
>  > original URL or the URL traversed to.
>  > 
>  > Maybe the VHM should add a key like VIRTUAL_URL that isn't changed on 
>  > traversal like URL.
> 
> There is "PATH_INFO", the unprocessed URL as requested from Zope.
> It may, of course, contain the path components controlling the VHM.

Yes. The VHM components are the problem. And maybe the missing query 
component.


Cheers,
	Yuppie





More information about the Zope-CMF mailing list