You are viewing a plain text version of this content. The canonical link for it is here.
Posted to docs@cocoon.apache.org by Conal Tuohy <co...@paradise.net.nz> on 2002/07/10 02:19:27 UTC

RE: generating a manifest of xml docs

I'm glad I could help, icewind.

The xinclude elements refer to another Cocoon pipeline, which extracts the
title from the tei doc, where it is located at
"TEI.2/teiHeader/fileDesc/titleStmt/title/text()". This other pipeline
extracts this "TEI.2/teiHeader/fileDesc/titleStmt/title/text()" and produces
a document with a single top-level element "title":

<title>Some Book Title</title>

So the xpointer fragment #xpointer(/title/text()) is just to take the text
from out of THIS document.

Why the 2-step process?

I could have xincluded it directly by referring directly to the source TEI
document and using an xpointer of
"TEI.2/teiHeader/fileDesc/titleStmt/title/text()", but I wanted to be able
(later) to define the book title differently, perhaps including the contents
of other elements than just "TEI.2/teiHeader/fileDesc/titleStmt/title", such
as TEI.2/teiHeader/fileDesc/publicationStmt/publisher", etc.

This is a separation of concerns: the first XSLT is concerned with defining
an html page of links to xml documents, where the 2nd XSLT is concerned with
the semantics of TEI, i.e. "what constitutes the 'title' of a TEI document?"

Con

> -----Original Message-----
> From: icewind [mailto:icewind0@yahoo.com]
> Sent: Wednesday, 10 July 2002 11:41
> To: cocoon-users@xml.apache.org
> Subject: RE: generating a manifest of xml docs
>
>
>
>
> Conal,
>
> Thank you very much for taking the time to explain
> your setup to me. I have found it to be very valuable
> and I think others on the list will too.
>
> I got it working on my setup by including the full
> XPath expression for the node I want to select in the
> xinclude tag. I's a little uncertain about the
> fragment "#xpointer(/title/text()". What exactly does
> that do? Is that a tag that you are looking for in the
> ebook? At first I thought it was but then I saw you
> using the XPath to extract the title in the stylesheet
> that extracts the title for you.
>
> Thanks.
>
>
> __________________________________________________
> Do You Yahoo!?
> Sign up for SBC Yahoo! Dial - First Month Free
> http://sbc.yahoo.com
>
> ---------------------------------------------------------------------
> Please check that your question  has not already been answered in the
> FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>
>
> To unsubscribe, e-mail:     <co...@xml.apache.org>
> For additional commands, e-mail:   <co...@xml.apache.org>
>
>