如何在 epub 的目录中设置条目,链接到章节中的位置?我已经尝试了我能想到的一切,并且总是从 epubcheck 3 收到错误消息。
我的 .opf 包含
<item id="Chapt1" href="Stockmarket7.xhtml" media-type="application/xhtml+xml" />
<item id="Link1" href="Stockmarket7.xhtml#Link1" media-type="application/xhtml+xml" />
<item id="Link2" href="Stockmarket7.xhtml#Link2" media-type="application/xhtml+xml" />
<item id="Link3" href="Stockmarket7.xhtml#Link3" media-type="application/xhtml+xml" />
<item id="Link4" href="Stockmarket7.xhtml#Link4" media-type="application/xhtml+xml" />
这会在错误列表中创建许多条目,类似于:
<message>RSC-001, ERROR, [File 'Stockmarket7.xhtml#Link1' could not be found.], Stockmarket.epub</message>
<message>RSC-001, ERROR, [File 'Stockmarket7.xhtml#Link2' could not be found.], Stockmarket.epub</message>
<message>RSC-001, ERROR, [File 'Stockmarket7.xhtml#Link3' could not be found.], Stockmarket.epub</message>
<message>RSC-001, ERROR, [File 'Stockmarket7.xhtml#Link4' could not be found.], Stockmarket.epub</message>
我的 .ncx 包含:
<navPoint id="Link1" playOrder="8">
<navLabel><text>Nasdaq and the Big Bang</text></navLabel>
<content src="Stockmarket7.xhtml#Link1"/></navPoint>
并且内容页面有一个 UL,包含:
<li id="Chapt1"><a href="Stockmarket7.xhtml#Chapt1">1 The Power of the Internet</a></li>
<li id="Link1"><a href="Stockmarket7.xhtml#Link1">Nasdaq and the Big Bang</a></li>
<li id="Link2"><a href="Stockmarket7.xhtml#Link2">The Internet opens the door wide</a></li>
<li id="Link3"><a href="Stockmarket7.xhtml#Link3">Not all has been positive</a></li>
<li id="Link4"><a href="Stockmarket7.xhtml#Link4">Playing the game</a></li>
我没有在互联网上找到任何有用的东西。谢谢伊恩