This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
Re: XSLT question - referencing one node and the oneafter it
- To: Dan York <dyork at e-smith dot com>
- Subject: Re: DOCBOOK-APPS: XSLT question - referencing one node and the oneafter it
- From: Daniel Veillard <veillard at redhat dot com>
- Date: Mon, 10 Sep 2001 12:03:01 -0400
- Cc: docbook-apps at lists dot oasis-open dot org
- List-Id: <docbook-apps.lists.oasis-open.org>
- References: <20010910111426.D31553@e-smith.com>
- Reply-to: veillard at redhat dot com
On Mon, Sep 10, 2001 at 11:14:28AM -0400, Dan York wrote:
> I am writing up an XSLT stylesheet to convert a document from
> another XML format (custom DTD) to DocBook XML. I've run into a
> stumbling block... all my XSLT books are at home... and I want
> to demo this stylesheet this afternoon... so I thought I would
> just bounce the question out here in case anyone here might have
> the quick answer... (if you do, MANY thanks!)
use
item[position() mod 2 = 0]
as the select pattern for row, and use
following-sibling::item[1]
to address the next consecutive item in that template
Daniel
--
Daniel Veillard | Red Hat Network http://redhat.com/products/network/
veillard@redhat.com | libxml Gnome XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
----------------------------------------------------------------
To subscribe or unsubscribe from this elist use the subscription
manager: <http://lists.oasis-open.org/ob/adm.pl>