I'm using HTML (App.special_dtml.HTML) for inline DTML template in my product.But I can't get it to stop quoting HTML entities like . How do I turn of quoting form HTML templates? Best Regards, Johan Carlsson
Johan Carlsson wrote at 2003-5-27 10:12 +0200:
I'm using HTML (App.special_dtml.HTML) for inline DTML template in my product.But I can't get it to stop quoting HTML entities like .
How do I turn of quoting form HTML templates?
You must render (i.e. call) them. When you access them without rendering, you effectively call its "__str__" method that returns the HTML quoted source. Dieter
Dieter Maurer wrote:
Johan Carlsson wrote at 2003-5-27 10:12 +0200:
I'm using HTML (App.special_dtml.HTML) for inline DTML template in my product.But I can't get it to stop quoting HTML entities like .
How do I turn of quoting form HTML templates?
You must render (i.e. call) them. When you access them without rendering, you effectively call its "__str__" method that returns the HTML quoted source.
So I noticed when looking at the code, but it do call them: HTML(template, globals())(self,REQUEST=REQUEST) I really don't understand why this should be any different from calling a DTMLFile. Strange? Best Regards, Johan Carlsson
Johan Carlsson wrote at 2003-5-27 22:57 +0200:
Dieter Maurer wrote:
Johan Carlsson wrote at 2003-5-27 10:12 +0200:
I'm using HTML (App.special_dtml.HTML) for inline DTML template in my product.But I can't get it to stop quoting HTML entities like .
How do I turn of quoting form HTML templates?
You must render (i.e. call) them. When you access them without rendering, you effectively call its "__str__" method that returns the HTML quoted source.
So I noticed when looking at the code, but it do call them:
HTML(template, globals())(self,REQUEST=REQUEST)
I really don't understand why this should be any different from calling a DTMLFile. Strange?
Where do you use the result? In ZPT? Then, you will need a structure. Otherwise, calling the template (as shown above) should not HTML quote. Dieter
participants (2)
-
Dieter Maurer -
Johan Carlsson