[Zope-CMF] Re: Serious problem with type actions
Yuppie
schubbe@web.de
Tue, 29 Apr 2003 16:32:16 +0200
Hi!
Ronan Amicel wrote:
> The problem means you cannot get *both* the <base> tag right
> and have type actions work, which is too bad...
>
> The work on ti_apb branch may be an opportunity to push the
> integration of type actions with the general actions mechanism
> further? I hope this can be fixed for CMF 1.4 anyway, so if
> someone sees how to solve this... :-/
I think all actions should be absolute URLs by default. Are there any
use cases that need relative URLs / method names?
current: string:document_view
proposed: string:${object_url}/document_view
As you mentioned on the collector, this breaks the usage of _getViewFor
and getActionById.
getActionById is (besides the 'mkdir' hack) used to build absolute URLs.
Resolved in the right context, returning an absolute URL would improve
this method.
_getViewFor is used to return the default view. I'm sure this could also
be done with an absolute URL.
The difficult part seems to be the migration path:
If we allow absolute URLs and relative URLs / method names, what should
getActionById return? If it returns the absolute URL, the skins have to
be changed and old sites don't work with the new skins.
If we just allow absolute URLs, we need to convert all type actions. We
have to know when and how to convert the actions. This breaks old skins
used by converted sites.
Just my 2 cents.
Yuppie