Hi,
I have tried to create a pdf from several html files and generate a table of contents. I have tried to follow the quick guide to creating Table of Contents in Prince 14, but I have failed to do so. Output pdf is created including all files, but table of contents is empty. I am using Prince 14.3. Can you help me?
Thanking you in advance
command
prince-style.css
toc.html
chapter-1.html
chapter-2.html is similar to chapter-1.html
I have tried to create a pdf from several html files and generate a table of contents. I have tried to follow the quick guide to creating Table of Contents in Prince 14, but I have failed to do so. Output pdf is created including all files, but table of contents is empty. I am using Prince 14.3. Can you help me?
Thanking you in advance
command
prince.exe ^
-s prince-style.css ^
toc.html ^
chapter-1.html ^
chapter-2.html ^
-o output.pdf
prince-style.css
html { font-family: sans-serif; }
#toc li { list-style-type: none }
#toc a:after { content: leader('. ') target-counter(attr(href), page) }
toc.html
<head>
<meta charset="utf-8">
<title>TOC</title>
<script src="https://princexml.com/howcome/2020/guides/charms.js"></script>
</head>
<body onload="toc('h1, h2')">
<h1>Table of contents</h1>
<ol id="toc"></ol>
</body>
chapter-1.html
<head>
<meta charset="utf-8">
<title>Chapter 1</title>
</head>
<body>
<h1>Chapter 1</h1>
<p>Veniam eiusmod cillum esse eiusmod non.</p>
<h2>First item</h2>
<p>Enim dolor aliquip est laboris.</p>
<h2>Second item</h2>
<p>Culpa reprehenderit elit</p>
</body>
chapter-2.html is similar to chapter-1.html