Skip navigation
Currently Being Moderated

Internal links to images in epub export?

Mar 8, 2012 3:05 PM

Tags: #epub_export

I am using CS5.5 to export a rather large book, with many images, to epub.

 

I am using the cross-reference function to create internal links from some parts of the text to others. Is there a way I can do this with images? (As in (see photo.) )

 

Right now I am trying it by linking to a text anchor in the caption, but sometimes in the final export the caption is not on the same page as the photo, so the link does not go to the image and is confusing.

 

I feel like there has to be a way to do this, but after quite a bit of research I am still at a loss.

 

Thanks for the help.

 
Replies
  • Currently Being Moderated
    May 23, 2012 8:31 PM   in reply to m.e.long

    It sounds as if your caption is beneath the object to which it's referencing. If so, you can either do one of two things. The first thing (and doesn't require any XHTML knowledge) is to place the caption above the image (a bit unconventional in comparision to dead-tree printing). This will cause the e-reader to begin the page with the caption (the linked item) and thus contain the object of reference below, ensuring it's on the same page for viewing.

     

    Another option, and a more elegant solution (but more technical), is to open the EPUB file with an app like BBEdit or TextMate. Both of these apps can open an EPUB file without having to unzip the file. With the file open, navigate to the file in which you want to make your edit (which will be located in the OEBPS folder). Run a Regex search for your caption title (regex \bcaption\b) and ensure you've found the correct location. Locate your <a id="caption" /> destination anchor. The code just above this anchor should be your image. Remove this code above the image with a p class, like so: <p class="caption"><a id="caption1" />&#160;</p>. This effectively forces the ereader to display the object of reference.

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points