I have an XML file that looks like this:
<A>
<B.../>
<C.../>
<C.../>
<C.../>
<D.../>
<D.../>
</A>
I am trying to come up with a way to format it like this using XSLT:
<A>
<B.../>
<C.../>
<D.../>
</A>
I have tried a number of things like using for-each loops that...
When you use preceding-sibling it parses in opposite order as following sibling.
Ex.
last(),[2],[1],current(),[1],[2],last()
by default preceding sibling take the first preceding node so take away the [1] and it should work.
I just had problems with this, hope it helps.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.