View Single Post
Old 03-06-2012, 11:12 AM   #1
iain robinson
Connoisseur
iain robinson began at the beginning.
 
Posts: 75
Karma: 10
Join Date: Apr 2011
Location: UK
Device: none
iBooks problem with text anchors

Hi all

We're making ePUBs in Adobe Indesign CS5.5 and then manipulating them to suit our requirements. One requirement is that the customer wants links after each endnote that you can click on to take you back to the appropriate place in the text. I know that there is a link at the foot of the page iBooks for this anyway but the customer still wants it (will be useful on other devices no doubt). When the user clicks an endnote reference in the text it takes you to the endnotes (Indesign takes care of this bit) and we add programmatically some anchors to the endnote references in the text and then put a link to them after the endnote.

Problem is that in iBooks (v2.0.1) the links sometime don't lead you back to the correct reference. In an article with 10 endnotes for example, the first 4 will work as expected then 5-7 will take you back to note reference 4, then 8-10 will work okay. If I uncompress the ePUB and view the html file in Safari all the links work as expected. Is this an iBooks bug and if so how are other people getting round it?

An example of some code from the text;
Code:
<p class="main-text">And all because of a couple of pieces of legislation being discussed in the USA, the Stop Online Piracy Act and the Protect IP Act (SOPA<a id="Anchor-1031"></a><a href="#Anchor-31"><span class="superscript">1</span></a> and PIPA<a id="Anchor-1032"></a><a href="#Anchor-32"><span class="superscript">2</span></a> respectively).
An example of some code from the endnotes;
Code:
<ol>
	<li class="endnotes"><a id="Anchor-31"/><a href="www.blahblah.com">www.blahblah.com</a>.<a href="#Anchor-1031" class="orange"> [BACK]</a></li>
	<li class="endnotes"><a id="Anchor-32"/><a href="www.ihateibooks.com">www.ihateibooks.com.</a><a href="#Anchor-1032" class="orange"> [BACK]</a></li>
Any help gratefully received,
Iain
iain robinson is offline   Reply With Quote