[Zope-CMF] Re: Priority CMF skins vs. Five views?

yuppie y.2006_ at wcm-solutions.de
Sat Apr 8 05:17:39 EDT 2006


Hi Andreas!


Not everybody on the Five list is interested in CMF specific questions. 
Since CMF builds on top of Five you are welcome to ask questions like 
this one on the Zope-CMF list.

Andreas Jung wrote:
> What is the lookup order of context/foo inside a CMF site when I have
> both foo.pt inside portal_skins and a brower:page with name="foo" 
> configured
> for the particular context object?

Skin method lookup uses __getattr__, so the more general question would 
be attribute lookup.

The lookup order was changed recently (Zope 2.9.2) as described here: 
http://codespeak.net/pipermail/z3-five/2006q1/001186.html

So the answer to your question depends on the version you use.


The CMF Method Aliases use __before_publishing_traverse__ which is 
called before Five traversal. They can be used to map 'foo' to '@@foo', 
making sure the view wins always over the skin method, regardless of the 
Five version used.


Cheers,

	Yuppie





More information about the Zope-CMF mailing list