[ZPT] Re: [Zope] prevent quoting in tal:attributes

Fergal Daly fergal at esatclear.ie
Wed Oct 1 16:17:46 EDT 2003


On Wednesday 01 October 2003 18:35, Evan Simpson wrote:
> Fergal Daly wrote:
> > and
> > 
> > hello &name"how are you"
> > 
> > into
> > 
> > hello &name"how are you"
> 
> This was already implemented for static attribute values, and I've made 
> it also work for dynamic attributes in the CVS trunk and 2.7 branch. 
> See bug #721 in the Collector.

I can see why for static ones, there's not much expanding the entity when you 
can just pass it back out again but for dynamic ones it seems a little odd 
(or maybe I've misunderstood).

Is it the case that if

val = """

then <t tal:attributes="attr val"> will produce <tag att="&quot;"> instead of 
<tag attr="&amp;quot;">? Or do I have to do something like <tag 
tal:attributes="attr structure val"> for it to kick in?

I can understand the wish to sometimes put entities into attributes but if 
it's enabled by default, without a way to turn off then that's not good there 
are plenty of situations where you definitely want "&something;" to be 
substituted into the document as "&amp;something;",

F




More information about the ZPT mailing list