Mobileread
Different footnote/link behavior resulting from epub formatting -- how?
#1  graatch 06-02-2020, 05:36 PM
I originally posted here and regarding Moonreader, since there are epub programs which ignore this distinction entirely, but it certainly seems to be a result of something in the epub formatting, no?

https://www.mobileread.com/forums/sh...d.php?t=330267

In Moonreader sometimes footnote links ‘jump’ to a different part of the text and at other times the footnote link just brings up the note (in a nice yellow "sticky note", as of the last update) without jumping you around -- in what's brought up you have the option to 'open' the destination which then takes you there. For me a book full of footnotes in the former style is borderline unreadable as it’s too easy to be moved to different parts of the text. I’ve been looking and looking at hrefs in html and epub, as well as the offending files in Sigil, and for the life of me I can’t figure out what causes a link to do one rather than the other.




So, for example, in my epub of Macbeth:

image »

"Nothing afeard" brings up a popup, which is good, whereas "what thyself didst make" jumps to the note at the end of the file, which is not good.

The underlying formatting is this ugliness:

Quote
<br/>********<a id="aa1s3l99"></a><a class="hlink" href="../Text/Footnote.htm#a1s3l99">Nothing afeard<sup>99</sup></a> of <a id="aa1s3l99a"></a><a class="hlink" href="../Text/Footnote.htm#a1s3l99a">what thyself didst make</a>,<br/>
and the footnotes:

Quote
<p class="footnote" id="a1s3l99"><a class="hlink" href="../Text/Shak_9781588368331_epub_c01_r1.htm#aa1s3l99"><stro ng><sup>99</sup> Nothing afeard</strong></a> not at all afraid **</p>
<p class="footnote" id="a1s3l99a"><a class="hlink" href="../Text/Shak_9781588368331_epub_c01_r1.htm#aa1s3l99a"><str ong>what … make</strong></a> i.e. slaughter on the battlefield (<strong>strange images of death</strong>)**</p>

It seems the only difference is that one receives a numeral in superscript and the other doesn't? What am I missing?
Reply 

#2  jackie_w 06-02-2020, 08:01 PM
Quote graatch
It seems the only difference is that one receives a numeral in superscript and the other doesn't? What am I missing?
No guarantees, but you could experiment with always keeping the id="..." and the href="..." attributes together in a single <a> tag, rather than splitting them over
- two <a> tags (as in your chapter HTML) or
- a <p> and an <a> tag (as in your endnote HTML).

Like this:
Code
<br/>********<a class="hlink" id="aa1s3l99" href="../Text/Footnote.htm#a1s3l99">Nothing afeard<sup>99</sup></a> of <a class="hlink" id="aa1s3l99a" href="../Text/Footnote.htm#a1s3l99a">what thyself didst make</a>,<br/>
<p class="footnote"><a class="hlink" id="a1s3l99" href="../Text/Shak_9781588368331_epub_c01_r1.htm#aa1s3l99"><strong><sup>99</sup> Nothing afeard</strong></a> not at all afraid **</p>
<p class="footnote"><a class="hlink" id="a1s3l99a" href="../Text/Shak_9781588368331_epub_c01_r1.htm#aa1s3l99a"><strong>what … make</strong></a> i.e. slaughter on the battlefield (<strong>strange images of death</strong>)**</p>
I've had more consistent results with pop-up footnotes in various apps since I started doing this. Don't ask me why, though.
Reply 

#3  Quoth 06-03-2020, 01:44 AM
The size of the destination paragraph can have an effect, but varies by app, ereader and epub vs kepub on Kobo.
Reply 

#4  graatch 06-03-2020, 07:15 PM
Appreciate that tip Jackie, I'll try it!

Quoth, that's a good point -- there would have to be some limitation I'm sure, though it can't be operative in this case since the footnotes are both short, well shorter than other notes that popup for me.
Reply 

Today's Posts | Search this Thread | Login | Register