[ZPT] 'here' vs 'container' in the context of an object ..
Jean Jordaan
jean@upfrontsystems.co.za
Tue, 27 Aug 2002 09:06:55 +0200
Hi all
I'm moving a DTML-based site over to ZPT. I used to have this:
http://server/folder/msworddoc/view
where 'msworddoc' is a "MSWord Document" instance (but it could've
been any other object) and 'view' is a DTML method that does::
<dtml-var comments>
<dtml-var text>
where 'comments' and 'text' are properties of 'msworddoc'. The
replacement ZPT starts like this::
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
lang="en" metal:use-macro="here/template/macros/page">
[...]
<p tal:content="here/comments"></p>
[...]
</html>
This fails:
Error Type: Undefined
Error Value: macros not found in 'here/template/macros/page', at line 3, column 1
If I change the macro call to
'metal:use-macro="container/template/macros/page"', it works. It
looks like 'template' can't be acquired from 'here', but it can be
acquired from 'container'. But then why doesn't the error message say:
"**template** not found in 'here/template/macros/page'"? Surely if
you've found template, you have the macros in it?
This bugs me, because I have
'metal:use-macro="here/template/macros/page"' everywhere else,
and I wouldn't like to worry about where it should be 'container'
instead.
--
Jean Jordaan
Upfront Systems http://www.upfrontsystems.co.za