[Zope] I don't understand a specific <dtml-var> behavior

Chris McDonough chrism@digicool.com
Tue, 8 Feb 2000 15:26:20 -0500


<dtml-var id> is equivalent to <dtml-var name=id>
<dtml-var "id"> is equivalent to <dtml-var expr="id">

The first is named syntax.  What follows the = is an object identifier.

The second is expression syntax.  What follows the = is a python
expression.

<dtml-var "id"> returns the object referred to by the id.
<dtml-var id> returns the string representation of the object's id.
<dtml-var "id()"> returns the string representation of the object's id.

Welcome to hell.  ;-)

Read this:

http://www.zope.org/Members/mcdonc/HowTos/gainenlightenment



> -----Original Message-----
> From: danny shevitz [mailto:danny_shevitz@yahoo.com]
> Sent: Tuesday, February 08, 2000 1:24 PM
> To: zope
> Subject: [Zope] I don't understand a specific <dtml-var> behavior
> 
> 
> I'm still trying to learn DTML and in particular the various rules for
> when to quote or not or...
> 
> I have come across the following syntactic issue which I don't
> understand.
> 
> <dtml-var title> puts the title in the document. Fine.
> <dtml-var "title"> puts the title in the document. Fine.
> <dtml-var id> puts the id in the document. Fine.
> <dtml-var "id"> puts Nothing in the document. ????.
> 
> Danny
> __________________________________________________
> Do You Yahoo!?
> Talk to your friends online with Yahoo! Messenger.
> http://im.yahoo.com
> 
> _______________________________________________
> 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 )
>