[Zope3-Users] Re: View:for="*" and Class
sebastien.vinot at logisphere.fr
Mon Sep 11 08:40:18 EDT 2006
Philipp von Weitershausen a écrit :
> Sébastien VINOT wrote:
>> Is it possible to associate a class with a skin template ?
> Sure, but it won't help.
Sorry but why will it not help me ?
>> I tried to "customize" an example (from chap 24 "Zope3") but
>> unfortunately even if my zcml is read with no errors, the final view
>> used is the one associated with my component.
> Right, because when a ZPT uses a skin macro, the raw macro "byte code"
> is inserted into the the ZPT. That means all TALES variables are bound
> to the actual view, not the skin.
Okay, but (stop me if I'm wrong) a template can be associated to a
class. I took your example 8.2.4 (chapter 8.2 Page Template macros) and
thought the view class was "StandardMacros".
>> Is there a way to do this ?
> Define a view class for * that you will query from the macro, e.g.
I added (just for test) a function foo into your StandardMacros and
added into my skin template :
<metal:macro use-macro="context/@@StandardMacros/foo" />
And I get : TypeError: unsubscriptable object
(StandardMacros has your configuration).
Does my understand of your suggestion wrong ?
> Zope3-users mailing list
> Zope3-users at zope.org
More information about the Zope3-users