I have a problem with a bit XSLT that outputs the children of the current page in a nice set of li's and all wrapped up in div which makes it all look nice on the page. Here is the XSLT (just from the interesting bit down)
<!-- Standard stuff above here removed for the sake of brevity --> <xsl:variable name="level" select="2"/>
If no child node, don't output anything?
I have a problem with a bit XSLT that outputs the children of the current page in a nice set of li's and all wrapped up in div which makes it all look nice on the page. Here is the XSLT (just from the interesting bit down)
The problem is that if there is no child to output, I don't want the divs and stuff around it all to be output at all.
It's like I need to put a big IF around it all to test if the for-each is going to loop at all.Is that the solution? How do i do that?
I think the count function is what you'll require...
So obvious when you ask in the right place :)
Thanks Chris. Worked perfectly.
No problem (remember to mark posts as solved)
Sure. Where do I do that? The word 'Solved' only appears in your post on this page.
Do I just type it?
"It is Solved"
I can't even mark your post as Helpful. I don't have 70 Karma points.
Thanks again
Oops.. I found the Tick...
My bad
Solved..
is working on a reply...