Hi all,
is there a way to dynamically show/hide a table header row (xhtml:tr/xhtml:th) depending on whether the table contains data rows? Background: i use some tables to display xforms:repeat items. These tables should have a header row containing the Column Names. And i would be happy if i could hide that header row if there are no repeat items to display. I tried to achieve this with xsl:if test="count(...)", xforms:group ref=".[count(repeat) > 0]" and xforms:repeat nodeset=".[count(repeat) > 0]". But none worked as i wanted: - xsl:if doesn't dynamically change if i add or remove repeat items; - xforms:group has no visible effect on the display of the row (with Firefox); - xforms:repeat toggles the display of the header row, but the styles applied are those from the data rows. Can anybody help? florian -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
Administrator
|
Florian,
Ideally, this will be solved by making xforms:group around xhtml:tr. In the meanwhile, what about putting an xforms:group around the whole table? -Erik Florian Schmitt wrote: > Hi all, > > is there a way to dynamically show/hide a table header row > (xhtml:tr/xhtml:th) depending on whether the table contains data rows? > > Background: i use some tables to display xforms:repeat items. These > tables should have a header row containing the Column Names. And i would > be happy if i could hide that header row if there are no repeat items to > display. > > I tried to achieve this with xsl:if test="count(...)", xforms:group > ref=".[count(repeat) > 0]" and xforms:repeat nodeset=".[count(repeat) > > 0]". But none worked as i wanted: > - xsl:if doesn't dynamically change if i add or remove repeat items; > - xforms:group has no visible effect on the display of the row (with > Firefox); > - xforms:repeat toggles the display of the header row, but the styles > applied are those from the data rows. > > Can anybody help? > > florian > -- Orbeon Forms - Web Forms for the Enterprise Done the Right Way http://www.orbeon.com/ -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
Erik,
I still have that class that modifies the xforms:group to have generate an xhtml:tbody rather than an xhtml:span around xhtml:tr, using an appearance="xxforms:table" this works for us if you wanted to include it, or I can send it to Florian if not? Ryan Ryan Puddephatt "Measuring programming progress by lines of code is like
measuring aircraft building progress by weight." - Bill Gates Erik Bruchez wrote: Florian, -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
In reply to this post by Erik Bruchez
Hi Erik,
> Ideally, this will be solved by making xforms:group around xhtml:tr. > In the meanwhile, what about putting an xforms:group around the whole > table? You're right, that's the easiest solution - i don't know why i didn't found it myself. Thanks a lot! florian -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
Administrator
|
In reply to this post by Ryan Puddephatt
All,
FYI we will fix this one soon, hopefully the proper way! -Erik Ryan Puddephatt wrote: > Erik, > I still have that class that modifies the xforms:group to have > generate an xhtml:tbody rather than an xhtml:span around xhtml:tr, using > an appearance="xxforms:table" this works for us if you wanted to include > it, or I can send it to Florian if not? > > Ryan > > Ryan Puddephatt > Software Engineer > > Teleflex Group - IT UK > 1 Michaelson Square > Livingston > West Lothian > Scotland > EH54 7DP > > e> [hidden email] <mailto:[hidden email]> > t> +44(0)1506 407 110 > f> +44(0)1506 407 108 > w> www.teleflex.com <http://www.teleflex.com> > > "Measuring programming progress by lines of code is like measuring > aircraft building progress by weight." - /Bill Gates/ > "If you lie to the compiler, it will get its revenge." - /Henry Spencer/ > "It's hard enough to find an error in your code when you're looking for > it; it's even harder when you've assumed your code is error-free." - > /Steve McConnell/ > "If builders built buildings the way programmers wrote programs, then > the first woodpecker that came along would destroy civilization." - > /Gerald Weinberg/ > > > > Erik Bruchez wrote: >> Florian, >> >> Ideally, this will be solved by making xforms:group around xhtml:tr. >> >> In the meanwhile, what about putting an xforms:group around the whole >> table? >> >> -Erik >> >> Florian Schmitt wrote: >>> Hi all, >>> >>> is there a way to dynamically show/hide a table header row >>> (xhtml:tr/xhtml:th) depending on whether the table contains data rows? >>> >>> Background: i use some tables to display xforms:repeat items. These >>> tables should have a header row containing the Column Names. And i >>> would be happy if i could hide that header row if there are no repeat >>> items to display. >>> >>> I tried to achieve this with xsl:if test="count(...)", xforms:group >>> ref=".[count(repeat) > 0]" and xforms:repeat >>> nodeset=".[count(repeat) > 0]". But none worked as i wanted: >>> - xsl:if doesn't dynamically change if i add or remove repeat items; >>> - xforms:group has no visible effect on the display of the row (with >>> Firefox); >>> - xforms:repeat toggles the display of the header row, but the styles >>> applied are those from the data rows. >>> >>> Can anybody help? >>> >>> florian >>> >> >> >> ------------------------------------------------------------------------ >> >> >> -- >> You receive this message as a subscriber of the [hidden email] mailing list. >> To unsubscribe: mailto:[hidden email] >> For general help: mailto:[hidden email]?subject=help >> ObjectWeb mailing lists service home page: http://www.objectweb.org/wws >> -- Orbeon Forms - Web Forms for the Enterprise Done the Right Way http://www.orbeon.com/ -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
Free forum by Nabble | Edit this page |