Re: [xsl] removing nesting in data structure

Subject: Re: [xsl] removing nesting in data structure
From: Mike Brown <mike@xxxxxxxx>
Date: Mon, 20 May 2002 14:01:24 -0600 (MDT)
Andrew Welch wrote:
> Ive found a problem already... for some reason it applies subpara3
> twice.  Why is this?


In English, you're saying "Of all the element node children of
the current node, I want just those that do not have subpara1
children..." and so on.

You wanted something more like

*[not(local-name()='subpara1' or local-name()='subpara2')]



I posted a better example where you just go ahead and select all
children for processing, and have templates matching the ones you
expect to encounter.

Also, I question the wisdom of having distinct element types 'subpara1',
'subpara2', 'subpara3', when you could just have nested 'subpara' elements,
eliminating the need for numbering. Even then, if the content model of subpara
is (para,subpara?), then I'd be inclined to change the names to something like
paragroup & paracontent or something less confusing. ;)

   - Mike
  mike j. brown                   |  xml/xslt:
  denver/boulder, colorado, usa   |  resume:

 XSL-List info and archive:

Current Thread