[ZPT] Generating XML documents in ZPT

Dieter Maurer dieter at handshake.de
Mon Aug 16 13:14:15 EDT 2004


Philip Kilner wrote at 2004-8-16 09:22 +0100:
>Dieter Maurer wrote:
>>>- For consistency, I set the mime type of the ZPT to "text/xml" as 
>>>opposed to "text/html" - but this caused the template source to be rendered!
>> 
>> What does "the template source were rendered" mean?
>> 
>
>It means that when I call my template, I see: -
>
><GUID>
><span tal:replace="RequestRecord/GUID">GUID</span>
></GUID>

This (almost surely) has the following reason:

  Unlike the TAL HTML parser, the TAL XML parser does not
  provide default definitions of the "tal:" and "metal"
  namespace prefixes.

  Your XML template *MUST* define "xmlns:tal" and "xmlns:metal"
  (correctly).


-- 
Dieter


More information about the ZPT mailing list