You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there a way to jump to a specific paragraph within an epub? My end goal is to sync 2 books. When a user highlights a word in book1, I would like to know the paragraph id that this word belongs to. And then I would like to load book2, jumping to the location of the paragraph with the same id.
I see that I can do this on a page by page basis, using each spineItem's spineItemIndex and spineItemPageIndex and initializing/pushing to the navigationController a new EPubViewController. But I would like to narrow in to the paragraph level.
(Just thinking now...perhaps this would require giving each paragraph an id attribute when the epub's are being authored. <p id=1'>.......)
The text was updated successfully, but these errors were encountered:
The short answer is that you can target specific paragraphs in a unique fashion using CFIs (Canonical Fragment Identifiers). See http://www.idpf.org/epub/linking/cfi/epub-cfi.html.
The long answer will require some research and experimentation.
Hello.
Is there a way to jump to a specific paragraph within an epub? My end goal is to sync 2 books. When a user highlights a word in book1, I would like to know the paragraph id that this word belongs to. And then I would like to load book2, jumping to the location of the paragraph with the same id.
I see that I can do this on a page by page basis, using each spineItem's spineItemIndex and spineItemPageIndex and initializing/pushing to the navigationController a new EPubViewController. But I would like to narrow in to the paragraph level.
(Just thinking now...perhaps this would require giving each paragraph an id attribute when the epub's are being authored. <p id=1'>.......)
The text was updated successfully, but these errors were encountered: