On 12/10/05, Kevin Dangoor <[EMAIL PROTECTED]> wrote:
On 12/10/05, Dan R <[EMAIL PROTECTED]> wrote:
> Now if I try and do a
>
> <div py:if="ulevel <= 0"> Whatever </div>
>
> I get an ExpatError. The == < and > comparisons are ok. What's going on?
I would expect < to fail also... The template needs to be valid XML,
so it would seem like you need to do < in place of <.
Kevin
Yep. With XML the > is a legal character in an attribute value, while < is not[0]. It would be nice to have Kid encode things before they get passed to the parser. So we could get something like this to work:
<div py:if="${ulevel <= 0}">
But I am not sure how good of an idea this would be. I'll bring it up on the Kid mailing list after I think about it for a bit.
[0] http://www.w3.org/TR/2004/REC-xml-20040204/#NT-AttValue
-- David

