Better access to APIs in paths (was Re: [Zope3-dev] needing viewsclues - template/title troubles)

Shane Hathaway shane@zope.com
Mon, 24 Feb 2003 15:42:05 -0500


Jim Fulton wrote:
> I suggest that it would be better to have very few namespaces. Perhaps
> all of the standard apis should be in a standard, namspace. I wouldn't
> have a dc namespace. I might have a "dc" name in the standard namespace.
> I'd call the standard namespace "zope" or "api":
> 
>   context/zope:title
> 
> or:
> 
>   context/api:title
> 
> I prefer api.
> 
> I'd go so far as to allow the standard namespace to be spelled
> with an empty string:
> 
>   context/:title

That last suggestion doesn't look like a reference to an API.  Because 
it puts two punctuation marks together, it looks like some other kind of 
operation.  Also, "api" doesn't say *which* api the template is 
referring to.  So "zope" seems most preferable.

> Also note that this new syntax will be used in TALES outside of zpt.
> For example, it would be useful to use these in simple stand-alone
> TALES expressions where namespace declarations are inconventient or
> impossible,

That's an important consideration.  TALES is useful outside XML, so I 
guess we won't get XML namespaces involved at all.

(That's a bit of a shame, since I was trying to get Zope closer to XML 
and RDF through this mechanism, but I guess that's not important now.)

Shane