I've got a DTML document (id = review) with just straight HTML in it like this: <P>just some text</P> When I call it using <dtml-var review> it comes out ok, but when I call it from the parent as <dtml-var "_['child'].review">, the Zope returns the HTML code with all of the angle brackets coming back as HTML character entities. What's going on here? I'm using Zope 2.0b6 Vic
Victor Ng wrote:
I've got a DTML document (id = review) with just straight HTML in it like this:
<P>just some text</P>
When I call it using <dtml-var review> it comes out ok, but when I call it from the parent as <dtml-var "_['child'].review">, the Zope returns the HTML code with all of the angle brackets coming back as HTML character entities. What's going on here? I'm using Zope 2.0b6
Hmm. Can't you just say <dtml-var review>? If the review object is above the document, it will work. If it is below, you can say: <dtml-with child> <dtml-var review> </dtml-with> -Michel
Vic
_______________________________________________ Zope maillist - Zope@zope.org http://www.zope.org/mailman/listinfo/zope
(To receive general Zope announcements, see: http://www.zope.org/mailman/listinfo/zope-announce
For developer-specific issues, zope-dev@zope.org - http://www.zope.org/mailman/listinfo/zope-dev )
At 07:38 PM 8/30/99 -0500, Victor Ng wrote:
I've got a DTML document (id = review) with just straight HTML in it like this:
<P>just some text</P>
When I call it using <dtml-var review> it comes out ok, but when I call it from the parent as <dtml-var "_['child'].review">, the Zope returns the HTML code with all of the angle brackets coming back as HTML character entities. What's going on here? I'm using Zope 2.0b6
When say <dtml-var somevar>, you get the result of *executing* somevar, but if you say <dtml-var "somevar"> you will get somevar itself. It's somewhat like using a single-quote in LISP, which gives you a thing literally instead of what it stands for. Here are several ways to get what you want: <dtml-with child><dtml-var review></dtml-with> <dtml-var "child.review(_.None,_)"> <dtml-var "_.render(_,child.review)"> See the DTML guide for explanations.
participants (3)
-
Michel Pelletier -
Phillip J. Eby -
Victor Ng