Hi Bob,
Thank you for the suggestion. This is unfamiliar territory for me,
and I seem to have run into an obstacle implementing this suggestion:
"So you need to use your PDF stylesheet to generate separate data
files for PDF output."
Starting with a single book, I have created a separate target database
document (olinkdb-fo.xml) that is supposed to generate a separate
targets database (target-fo.db) However, I get an error message:
E [Saxon6.5.5] target-fo.db (Access is denied)
And the target-fo.db file does not get generated. A search on this
list suggested that to avoid this error I need to change my base.dir
to the location where the output files will be generated. So I have
specified that as:
C:/Activity/Cogent/Docs/DocsOx/Source/${cfn}/out/pdf/
(Where ${cfn} is a variable for the file name and directory name of
the current book, in this case it's 'DHScripting'.)
However, I still get the error. Here is the complete error message:
System ID: C:\Activity\Cogent\Docs\DocsOx\Source\DHScripting\dhs-book.xml
Scenario: Skkynet-PDF - TargetDB
XML file: C:\Activity\Cogent\Docs\DocsOx\Source\DHScripting\dhs-book.xml
XSL file: C:\Activity\Cogent\Docs\DocsOx\FO-SS-Book.xsl
Engine name: Saxon6.5.5
Severity: error
Description: target-fo.db (Access is denied)
My olinkdb-fo.xml file for the book contains this:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE targetset [
<!ENTITY dhstargets SYSTEM "./target-fo.db">]>
<targetset>
<targetsetinfo> Description</targetsetinfo>
<document targetdoc="./out/pdf/dhs-book.pdf"
baseuri="./out/pdf/dhs-book.pdf">
&dhstargets; </document>
</targetset>
The HTML version, olinkdb.xml, generates the target.db database as
expected. What am I doing wrong that is preventing me from generating
a PDF version?
As always, I greatly appreciate your help.
Best wishes,
Bob
COGENT <http://cogent.ca/>
*Bob McIlvride ** Communications Manager*
Cogent Real-Time Systems Inc., a Skkynet company
T 1 905 702 7851 ext 103
cogent.ca <http://cogent.ca/>
*From:*Bob Stayton <b...@sagehill.net>
*Sent:* Tuesday, August 07, 2018 6:06 PM
*To:* Bob McIlvride <bob.mcilvr...@skkynet.com>;
docbook-apps@lists.oasis-open.org
*Subject:* Re: [docbook-apps] Can't get olink to generate a working
link between books in a set
Ah, you need to keep your generated data files for HTML and PDF
outputs separate. That is, you need to generate target data with the
stylesheet you are using to generate output. When you use your HTML
stylesheet, it generates target data with .html references. So you
need to use your PDF stylesheet to generate separate data files for
PDF output. Those files with different names would be referenced by
the PDF version of the target database document.
Bob Stayton
Sagehill Enterprises
b...@sagehill.net <mailto:b...@sagehill.net>
On 8/7/2018 12:07 PM, Bob McIlvride wrote:
Hi Bob,
That would make sense. I’ve tried it, and although it now seems
to recognize the correct ID, it still comes up within a pointer to
an html file:
I’ve used the sample xml code that you suggested for my
olinkdb.xml file, as well as a number of other combinations. But
they all seem to yield essentially the same results.
Do you have any further thoughts?
All the best,
Bob
COGENT <http://cogent.ca/>
*Bob McIlvride ** Communications Manager*
Cogent Real-Time Systems Inc., a Skkynet company
T 1 905 702 7851 ext 103
cogent.ca <http://cogent.ca/>
*From:*Bob Stayton <b...@sagehill.net> <mailto:b...@sagehill.net>
*Sent:* Monday, August 06, 2018 11:46 AM
*To:* docbook-apps@lists.oasis-open.org
<mailto:docbook-apps@lists.oasis-open.org>
*Subject:* Re: [docbook-apps] Can't get olink to generate a
working link between books in a set
Hi Bob,
The problem is the setup of the target database document, with a
sitemap and separate baseuri attributes for each book. That setup
is for separate book PDF files trying to link to each other.
If you are processing the books as a single set element, you
should instead set it up as a sequence of document elements
without a sitemap and without @baseuri's, which should then form
relative links.
<targetset>
<document targetdoc="test-set">
&testsettargets;
</document>
<document targetdoc="dhs-book"
&dhstargets;
</document>
etc.
I haven't tested this, but I think it will work. Let me know if
it doesn't.
Bob
Bob Stayton
Sagehill Enterprises
b...@sagehill.net <mailto:b...@sagehill.net>
On 8/2/2018 2:07 PM, Bob McIlvride wrote:
Hi Bob,
Thank you for the quick reply.
> Do you use targetdoc attributes in your olink elements, and
are they different for each book?
Yes, for example, this olink is located in the text of the
book whose xml:id="dos-book”:
… (see <olink targetdoc="dhs-book"
targetptr="dhs-book">DataHub Scripting</olink>), which …
The link renders like this in the PDF document output:
When I took the above screenshot (OlinkOutput.png, attached)
the mouse was hovering over the text “DataHub Scripting”, as
highlighted in yellow. You can see how the link seems to be
looking for an external file.
> Is your target database document for PDF output set up as a
single document, and do you generate a single target.db file
for the set?
I believe so, but I could be mistaken. Below is a copy of the
olinkdb.xml file. It references the target.db of each of the
three books in the set (as I think it is supposed to) and
creates a single target.db file for the set. The id of the
output file is “test-set”, and the filename is test-set.pdf.
It is located in the directory shown in the screenshot above.
I don’t know why the string “oxygen-main.html” has been
appended to the filename.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE targetset [
<!ENTITY testsettargets SYSTEM "target.db">
<!ENTITY dhstargets SYSTEM "../DHScripting/target.db">
<!ENTITY dostargets SYSTEM "../DHODBCScripting/target.db">
<!ENTITY dwstargets SYSTEM "../DHWinScripting/target.db">]
>
<targetset>
<targetsetinfo>Description</targetsetinfo>
<sitemap>
<dir name="./">
<document targetdoc="test-set"
baseuri="test-set.pdf">
&testsettargets;
</document>
<document targetdoc="dhs-book"
baseuri="test-set.pdf">
&dhstargets;
</document>
<document targetdoc="dos-book"
baseuri="test-set.pdf">
&dhstargets;
</document>
<document targetdoc="dws-book"
baseuri="test-set.pdf">
&dhstargets;
</document>
</dir>
</sitemap>
</targetset>
I hope this helps clarify the situation a bit. If you need any
additional information or files, please let me know.
Best wishes,
Bob
COGENT <http://cogent.ca/>
*Bob McIlvride ** Communications Manager*
Cogent Real-Time Systems Inc., a Skkynet company
T 1 905 702 7851 ext 103
cogent.ca <http://cogent.ca/>
*From:*Bob Stayton <b...@sagehill.net> <mailto:b...@sagehill.net>
*Sent:* Wednesday, August 01, 2018 6:29 PM
*To:* docbook-apps@lists.oasis-open.org
<mailto:docbook-apps@lists.oasis-open.org>
*Subject:* Re: [docbook-apps] Can't get olink to generate a
working link between books in a set
Hi Bob,
I would need a little more clarity on your set up. Do you use
targetdoc attributes in your olink elements, and are they
different for each book?
Is your target database document for PDF output set up as a
single document, and do you generate a single target.db file
for the set?
Bob Stayton
Sagehill Enterprises
b...@sagehill.net <mailto:b...@sagehill.net>
On 8/1/2018 12:25 PM, Bob McIlvride wrote:
Dear friends,
After almost two years being moved to other tasks, I now have an
opportunity
to complete this project. The HTML output is working fine, but the
issue
now is PDF (FO) output. Here's a summary of what we would like to
do:
We have several books that we can publish individually in HTML
(actually
'webhelp' in oXygen) and in PDF outputs. Using the same source
files, we
are publishing those same books in sets--HTML and PDF output.
The challenge is that we would like to have active links between
the books
when they are in a set, which become plain text references when the
books
are published separately. We are using olinks to achieve this
goal, and
they work fine for HTML output.
However, when we generate PDF output, it seems that the olinks are
looking
for external documents, not for books within the set. Is there any
way to
point the olinks back into the set document and have them work in
the PDF
output as well?
Any suggestions would be much appreciated.
Best regards,
Bob
Bob McIlvride Communications Manager
Cogent Real-Time Systems Inc., a Skkynet company
T 1 905 702 7851 ext 103
cogent.ca
-----Original Message-----
From: Bob McIlvride<bob.mcilvr...@cogent.ca> <mailto:bob.mcilvr...@cogent.ca>
Sent: Monday, September 26, 2016 12:44 PM
To: 'Bob Stayton'<b...@sagehill.net>
<mailto:b...@sagehill.net>;docbook-apps@lists.oasis-open.org
<mailto:docbook-apps@lists.oasis-open.org>
Subject: RE: [docbook-apps] Can't get olink to generate a working
link
between books in a set
Hi Bob,
Thank you for pointing this out. It is working now, and I'm very
grateful
for your help!
Best wishes,
Bob
Bob McIlvride Communications Manager
Cogent Real-Time Systems Inc., a Skkynet company T 1 905 702 7851
ext 103
cogent.ca
-----Original Message-----
From: Bob Stayton [mailto:b...@sagehill.net]
Sent: Saturday, September 24, 2016 5:37 PM
To: Bob McIlvride<bob.mcilvr...@skkynet.com>
<mailto:bob.mcilvr...@skkynet.com>;
docbook-apps@lists.oasis-open.org
<mailto:docbook-apps@lists.oasis-open.org>
Subject: Re: [docbook-apps] Can't get olink to generate a working
link
between books in a set
Hi Bob,
I think the problem is in the targetdoc attributes in your
olinkdb.xml file.
The targetdoc value in both a document's olink element and in the
database
document element is just an identifier name, not a filename.
Those identifiers must match, and they will when you remove the
".xml"
from the targetdoc value in the database file.
There is a good reason why targetdoc is not a filename, and that is
because
filenames can be changed without having to rewrite dozens of olinks
embedded
in files.
Bob Stayton
Sagehill Enterprises
b...@sagehill.net <mailto:b...@sagehill.net>
On 9/23/2016 11:36 AM, Bob McIlvride wrote:
Dear friends,
I am having problems getting olinks to correctly generate links
between books in a set in HTML output. I want to be able to
output
independent books that contain references to content in other
books,
and when the books are produced as part of a set, these
references
should become links in HTML output.
I am using oXygen XML Editor 18.0 that uses Saxon to generate
HTML
output. I've set up project files for two books (srr-book.xml
and
dos-book.xml) and one set (test-set.xml) as a test. I have
inserted
one olink in the srr-book that points to a section in the
dos-book.
The test-set.xml document looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE set [
<!ENTITY % commonentities SYSTEM
"../../Source/Common/commonentities.ent" >
%commonentities;
]>
<set xmlns="http://docbook.org/ns/docbook"
<http://docbook.org/ns/docbook> version="5.0"
xmlns:xi="http://www.w3.org/2001/XInclude"
<http://www.w3.org/2001/XInclude>
xmlns:xlink="http://www.w3.org/1999/xlink"</a
<http://www.w3.org/1999/xlink>" xml:id=" <xml:id=>test-set">
<info>
<title>Test Set</title>
</info>
<xi:include href="../SRRModule/srr-book.xml"/>
<xi:include href="../DHODBCScripting/dos-book.xml"/>
</set>
The olink markup in the srr-book.xml document looks like this:
<para>Not to be confused with <olink targetdoc="dos-book"
targetptr="dos-overview">Overview Link</olink>,which is
something
altogether different.</para>
When the test-set.xml document is processed, oXygen gives this
error
message:
[xslt] Error: unresolved olink: targetdoc/targetptr =
'dos-book/dos-overview'.
And the HTML output where the link should be looks like this:
<p>Not to be confused with <span class="olink">Overview
Link</span>,
which is something altogether different.</p>
The olinkdb.xml files for the books and the set are as follows:
- srr-book.xml:
<?xml version="1.0" encoding="UTF-8"?>
<targetset>
<targetsetinfo> Description</targetsetinfo>
<document targetdoc="srr-book.xml">
<xi:include href="target.db"
xmlns:xi="http://www.w3.org/2001/XInclude"
<http://www.w3.org/2001/XInclude>/>
</document>
</targetset>
- dos-book.xml:
<?xml version="1.0" encoding="UTF-8"?>
<targetset>
<targetsetinfo> Description</targetsetinfo>
<document targetdoc="dos-book.xml">
<xi:include href="target.db"
xmlns:xi="http://www.w3.org/2001/XInclude"
<http://www.w3.org/2001/XInclude>/>
</document>
</targetset>
- test-set.xml:
<?xml version="1.0" encoding="UTF-8"?>
<targetset>
<targetsetinfo>A test of olink target sets.</targetsetinfo>
<document targetdoc="../SRRModule/srr-book.xml">
<xi:include href="../SRRModule/target.db"
xmlns:xi="http://www.w3.org/2001/XInclude"
<http://www.w3.org/2001/XInclude>/>
</document>
<document targetdoc="../DHODBCScripting/dos-book.xml">
<xi:include href="../DHODBCScripting/target.db"
xmlns:xi="http://www.w3.org/2001/XInclude"
<http://www.w3.org/2001/XInclude>/>
</document>
<document targetdoc="test-set.xml">
<xi:include href="target.db"
xmlns:xi="http://www.w3.org/2001/XInclude"
<http://www.w3.org/2001/XInclude>/>
</document>
</targetset>
The target.db content that results from these olinkdb.xml files
looks
correct. For example, here is the part that corresponds to the
dos-book that refers to the Overview section to which the olink
points:
<div element="book" href="dos-book.html" number=""
targetptr="dos-book">
<ttl>DataHub<sup
xmlns="http://www.w3.org/1999/xhtml"
<http://www.w3.org/1999/xhtml>>®</sup> ODBC Scripting</ttl>
<xreftext>DataHub<sup
xmlns="http://www.w3.org/1999/xhtml"
<http://www.w3.org/1999/xhtml>>®</sup> ODBC Scripting</xreftext>
<div element="chapter" href="dos-introduction.html"
number="1" targetptr="dos-introduction">
<ttl>Introduction</ttl>
<xreftext>Chapter 1, <em
xmlns="http://www.w3.org/1999/xhtml"
<http://www.w3.org/1999/xhtml>
>Introduction</em></xreftext>
<div element="section"
href="dos-introduction.html#dos-overview" number="1.1"
targetptr="dos-overview">
<ttl>Overview</ttl>
<xreftext>Section 1.1,
“Overview”</xreftext>
</div>
...
I think I am doing everything correctly and according to Bob
Stayton's
clear and well-written documentation, but apparently I have
missed
something. Can anyone see what I may be doing wrong?
Appreciatively yours,
Bob
COGENT<http://cogent.ca/> <http://cogent.ca/>
*Bob McIlvride ** Communications Manager*
Cogent Real-Time Systems Inc., a Skkynet company
T 1 905 702 7851 ext 103
cogent.ca<http://cogent.ca/> <http://cogent.ca/>
---------------------------------------------------------------------
To unsubscribe, e-mail:docbook-apps-unsubscr...@lists.oasis-open.org
<mailto:docbook-apps-unsubscr...@lists.oasis-open.org>
For additional commands,
e-mail:docbook-apps-h...@lists.oasis-open.org
<mailto:docbook-apps-h...@lists.oasis-open.org>
---------------------------------------------------------------------
To unsubscribe, e-mail:docbook-apps-unsubscr...@lists.oasis-open.org
<mailto:docbook-apps-unsubscr...@lists.oasis-open.org>
For additional commands,
e-mail:docbook-apps-h...@lists.oasis-open.org
<mailto:docbook-apps-h...@lists.oasis-open.org>
---------------------------------------------------------------------
To unsubscribe, e-mail:docbook-apps-unsubscr...@lists.oasis-open.org
<mailto:docbook-apps-unsubscr...@lists.oasis-open.org>
For additional commands, e-mail:docbook-apps-h...@lists.oasis-open.org
<mailto:docbook-apps-h...@lists.oasis-open.org>