Sorry for the bump but since this is 100% my issue, I thought it would be best not to create a new topic.
I just came across Prince today and I'm very much in the same boat as the thread creator: Using the Prince PDF plugin in Calibre, trying to convert an epub file with hyperlinks instead of true endnotes to a PDF that has them as footnotes on the same page.
Prince seems to be the only solution I found that has the capability to handle this properly. A workaround by means of converting epub -> docx -> pdf is unsuitable because there are apparently too many hyperlinks in the file for Word to handle (it goes unresponsive for 45min+ when I try to replace all hyperlinks with footnotes using VBA).
Could you please elaborate on your previous post and provide a sample script, Mike? The solution seems sound but I'm not sure how to realize it.
To clarify, the hyperlinks have the format of /path/to.html#ftn.footnoteid
It is actually possible to do a simple version of this purely in CSS using the target-content() function, see the attached example below. This will not capture markup present in the footnote elements however.
One minor issue: the footnotes2.html example refers to "a.hash", however on closer inspection Prince is currently returning the .hash value without a leading "#" character, which is incorrect. We will fix this in a future release of Prince, after which it will be necessary to use a.hash.substring(1) to access the ID.
Cony, I’m in the same boat and am trying to go via Word first - would you be willing to share the code you used in VBA? I’m not particularly au fait with the software, and know it didn’t work for you, but would like to give it a go!