Am 11.03.2010, 16:19 Uhr, schrieb Andrew Sawyers <>:

> Heya Charlie,
> The way I do this is register a view for * with the name I'm using for  
> the
> macro:
> <browser:page
>     for="*"
>     name="foo"
>     permission="zope2.View"
>     template="../path/to/"
> />
> Then in in the template:
> <metal:foo use-macro="here/@@foo/macro_to_use">
> Not sure if that's the SOP or what...but works for me.


I understand that and I've even had some success registering macros "the  
Zope 3 way" - although I'm not sure that I see any advantage this way to  
what you propose. However, zope.formlib.form.PageForm comes with it's own  
template which has macros and slots which I like to be able to use and the  
default __call__ will use this template or a replacement one defined in a  
View class template attribute. And it's creating a template that uses  
zope.formlib.form.default_page_template where I'm stuck.

Charlie Clark
Helmholtzstr. 20
D- 40215
Tel: +49-211-938-5360
GSM: +49-178-782-6226
Zope-CMF maillist  -

See for bug reports and feature requests

Reply via email to