5 Dec 17:24
Re: Problems with on-error?
On Wed 30-Nov-2005 at 12:59 +0000, Bruno Postle wrote: >Yes, looks like there are two bugs here: > >* The TAL spec says that 'on-error' should be treated as a > 'content' statement, but Petal replaces the entire tag. > >* The expression isn't being evaluated and is dumped as a simple > string. > >http://www.zope.org/Wikis/DevSite/Projects/ZPT/TAL%20Specification%201.4/#on-error Also the content of on-error is used without any checks, so it is possible for badly coded templates to generate invalid XML like so: <span petal:on-error="<">$fail/me</span> Unless someone else fancies tackling this, a full fix will have to wait. So I've put a note in the pod documentation that the implementation of on-error is incomplete, and added code to defang XML metacharacters in the output. -- -- Bruno


RSS Feed