[Seaside] Possible bug with <ul> generation?
Rick Flower
rickf at ca-flower.com
Tue Feb 6 17:55:34 UTC 2007
Philippe Marschall wrote:
> 2007/2/6, Rick Flower <rickf at ca-flower.com>:
>> I ran across this last night when perusing the generated code in my
>> test-web-app I've been working on (debugging firefox css issues I had)..
>> I have a block of code that populates an unordered list (for the Canvas
>> API).. The unordered list will contain the contents of a shopping cart.
>> In this case if that cart is empty, I should effectively get (in my
>> opinion) an empty list..
>
> Wouldn't that be invalid? ul is defined in the XHTML DTD as:
> <!ELEMENT ul (li)+>
> what means is has to have one or more il child nodes.
Sounds reasonable -- If that's the case, then perhaps the code could be
smart enough to know that no <li> tags have been generated and not
bother generating the parent <ul></ul> tag-pairs either.. However, that
sounds like a lot more work than it's really worth to me and possibly
a case where the code could perhaps get confused and do the wrong thing
I suppose (the old keep-it-simple adage)
More information about the Seaside
mailing list