[Zope] <dtml-with> / <dtml-in> bug or mistake?
Casey Duncan
casey@zope.com
27 Jun 2002 15:20:57 -0400
try also:
<dtml-with expr="projectxy['04templates'].concepts">
...
</dtml-with>
hth,
-Casey
On Thu, 2002-06-27 at 10:49, Andy McKay wrote:
> > When I instead try it like
> > this (with <dtml-in> or <dtml-with>) with a folder which has a number in
> > the id field, I recieve a syntax error!
>
> Everything in the double quotes is Python and in Python objects cannot begin
> with a number, in Zope they can. To get around this you can do:
>
> <dtml-with projectxy><dtml-with 04templates><dtml-with concepts>
> <dtml-var template>
> </dtml-with></dtml-with></dtml-with>
>
> or
>
> <dtml-with "restrictedTraverse('projectxy.04templates.concepts')">
> <dtml-var template>
> </dtml-with>
>
> Cheers.
> --
> Andy McKay
>
>
>
>
> _______________________________________________
> Zope maillist - Zope@zope.org
> http://lists.zope.org/mailman/listinfo/zope
> ** No cross posts or HTML encoding! **
> (Related lists -
> http://lists.zope.org/mailman/listinfo/zope-announce
> http://lists.zope.org/mailman/listinfo/zope-dev )