I forgot that the template that generates
the book title reference checks to see if the target is in the current.docid,
and doesn't output the title if it is (it is not useful to refer someone to the
book they are reading).
So current.docid is still needed even if
you are not using a sitemap.
----- Original Message -----
Sent: Tuesday, April 26, 2005 3:59
AM
Subject: RE: [docbook-apps] olinking and
sitemap
Thanks, that worked! I must say this is one of the most
helpful (_and_ useful ;-) lists I participate in.
Regarding 2) it does work without current.docid, the
document is linked correctly although the olink.doctitle parameter seems to
sieze to have any effect without them. The whole "in <document>"
part is missing unless I specify current.docid. A bug? I am using xsl
1.67.2, as mentioned.
/Andreas
From: Bob Stayton [mailto:bobs@sagehill.net]
Sent: den 26 april 2005 00:36
To: Andreas Lalloo;
docbook-apps@lists.oasis-open.org
Subject: Re: [docbook-apps]
olinking and sitemap
Hi Andreas,
1) It is correct that you only need
to use a sitemap if your output documents are in different directories.
If they are in the same directory, then you can omit the <sitemap> and
<dir> elements, and just include a straight list of <document>
elements.
<document targetdoc="a-devguide"
baseuri="a-devguide.pdf">...
<document ...
For PDF output, the baseuri attribute
must contain the filename of the PDF file, because that name is not available
to the stylesheet.
2) No current.docid is needed if no
sitemap is used.
3) The sitemap must start with a
<dir> element. The top-level dir contains all the other dir
elements. I should have the stylesheet check that. If you remove
all the sitemap and dir elements, you shouldn't get an error if the target
data has that entry.
----- Original Message -----
Sent: Monday, April 25, 2005 2:47
PM
Subject: [docbook-apps] olinking and
sitemap
Hello
list!
I am fighting to get cross-document
references to work for .pdf output. I've been reading Bob Stayton's
excellent book but still have some questions.
1) When reading chapter 23 I get the impression
the sitemap element is necessary only if the (html) output is in different
directories, to get relative links correct (last paragraph of section
"Setting up PDF olinking" hints about that). But if all my .pdf files are in
the same directory, do I still need to specify a sitemap? If not, what shall
I use to refer to the document in the very olink (targetdoc)? In the html
example there's an association in the document element targetdoc/baseuri -
does that mean I need a sitemap structure after all? Or is it just the
directory specification of the sitemap I can omit?
2) If all output pdfs are in the same
directory, do I still need to specify current.docid?
3) Currently my biggest problem is that I get
the error
Olink error: cannot locate targetdoc a-devguide in
sitemap
although the master database file has an entry like
<sitemap>
<document targetdoc="a-devguide"
baseuri="
file://a-devguide.pdf">
&a-devguide_targets;</document>
when
processing
<olink targetdoc="a-devguide"
targetptr="chref_devg_mmf" />
If I remove all
of the <sitemap> element, I get another error (Error: unresolved
olink: targetdoc/targetptr = 'a-devguide/chref_devg_mmf'.) so obviously the
sitemap is seen by processing step.
I use DTD V4.3 and xsl
1.67.2, xsltproc and XEP by the way.
Thanks in advance
Andreas