I'm using iTextSharp to convert some ePubs to PDF and the conversion is working fine except for the TOC of the ePubs.
The points where the TOC links are linking too are generally in the format <a id
but I need them in the format <a name
, so I've been doing a string replace to get them in the correct form. However I have now found an ePub that does it's internal links differently and the href of the TOC links is linking too.
<h2 class="c007" id="chapII.">CHAPTER II.</h2>
And this document uses <a id
in a different unrelated scenario. So replacing <a id
with <a name
is no longer an option.
Is there a better way to fix the Internal links so that they successfully work.