Re: tal/petal naming bug?

Jean-Michel Hiver <[email protected]>
Newsgroups gmane.comp.lang.perl.modules.petal
Message-ID <[email protected]>
Kevin Teague wrote:
> Is the following a known bug in Petal?
> 
> <html>
> <body>
>   <div metal:use-macro="foo.pt#bar" />
> </body>
> </html>
> 
> And then within the foo.pt macro:
> 
> <div metal:define-macro="bar">
>   <p tal:content="somevar" />
>   <p metal:content="somevar" />
> </div>

metal:content will *not work*...


> Only the second paragraph works, it seems that within a macro Petal only 
> recognizes the "petal:" syntax and not the "tal:" syntax.
> 
> Also, thanks for implementing the metal:define-macro and metal:use-macro 
> functions, these make writting larger TAL sites much nicer.

from 'perldoc Petal'

   NAMESPACE

   Although this is not mandatory, Petal templates should include use the
   namespace http://purl.org/petal/1.0/. Example:

     <html xml:lang="en"
           lang="en"
           xmlns="http://www.w3.org/1999/xhtml"
           xmlns:tal="http://purl.org/petal/1.0/">

       Blah blah blah...
       Content of the file
       More blah blah...
    </html>


As for METAL, metal:define-slot and metal:fill-slot should work as of 2.07.

Also, i18n: is well on the way and should be there *very soon* :-)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.