[Zope3-dev] [OT] Re: idea: attr:foo addition to tal

Tonico Strasser contact_tonico at yahoo.de
Sun Jul 25 08:47:38 EDT 2004


Stuart Bishop wrote:
  > I suspect it is perfectly valid XML (':' is valid in XML
> names, which is how come they were able to use it for
> XML namespaces). A quick look at the namespaces spec
> seems to tell me that the namespace prefix is 'attr' and
> the attribute name 'xml:lang',

Hello Stuart,

maybe well-formed, but how would you validate it?

In theory we could validate TAL or METAL because we know the attributes 
in this namespace, but it's impossible to validate a unknown set of 
attributes.

I found this at the ZPT project wiki:

   The statements of the language are document tags with special
   attributes, and look like this:

       <p ns:command="argument">Some Text</p>

   [...]

   Also, parsing or writing a DTD for attribute languages is hard if the
   name of any statement attribute contains "data". Examples:

       Bad: <div ns:set="foo=1" ns:set="bar=2">
       Bad: <div ns:set-foo="1" ns:set-bar="2">
       Good: <div ns:set="foo=1, bar=2">

<http://zope.org/Wikis/DevSite/Projects/ZPT/AttributeLanguage>

(I havent't found a DTD for TAL or METAL now ;)

Tonico



More information about the Zope3-dev mailing list