12-29-2012, 04:08 PM | #1 |
Member
Posts: 10
Karma: 10
Join Date: Feb 2012
Location: Northeast US
Device: iPad 2, old Kindle
|
How to have a TOC entry link to mid-chapter?
I'm using the InDesign 5.5 Book feature to convert a printed book to ePub. The main chapters are divided into separate files to provide page breaks, but each chapter has sub-chapters that need second-level (at least) TOC entries.
The subchapters don't start on new pages in the printed book and I need to follow that format. a) How can I add the TOC entries that jump to the subchapters (either in Indesign or Dreamweaver 5.5) without creating a page break when the user is reading straight through? b) How can I indent these TOC entries to get 2nd and 3rd levels? |
12-29-2012, 04:22 PM | #2 | |
Well trained by Cats
Posts: 29,836
Karma: 54837878
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
<a id="midway">(optional words)</a> then the TOC should reference the Anchor: <content src="Text/index_split_004.xhtml#midway"/> (I prefer to use a full link instead of a relative link(the red part) ) Last edited by theducks; 12-29-2012 at 04:22 PM. Reason: Moved example |
|
12-29-2012, 05:25 PM | #3 |
Curmudgeon
Posts: 629
Karma: 1623086
Join Date: Jan 2012
Device: iPad, iPhone, Nook Simple Touch
|
I would suggest that you not include any text within a destination anchor. Some readers (ADE, I think) incorrectly style all anchors as though they were links. (I discovered this quite by accident last week.)
You can't really fix this in CSS because "color: WindowText" and "color: -webkit-text" aren't globally supported, and setting it to black will wreck display on readers in inverse-color mode. So basically, just always leave non-link anchors empty. |
12-29-2012, 06:24 PM | #4 |
Member
Posts: 10
Karma: 10
Join Date: Feb 2012
Location: Northeast US
Device: iPad 2, old Kindle
|
EDIT: Figured it out - it worked all along, it just didn't bring the anchor to the top of the page - ADE navigates so my subhead is in the middle of the page. Any way to have the subhead at the top? Or is this just an ADE glitch?
Thank you so much! Original post, ignore: OK, I added an "empty" anchor in InDesign (no text highlighted) before my subhead name, added an entry in the ncx file using the … chapterX.html#anchorname code and re-numbered all the navPoints and playOrders in DW. I now have the correct TOC entry, but it takes me to the beginning of the main chapter - not the anchor within it. I'm previewing in ADE, as my device isn't here - is that the problem, or do I have to do something else to get it to go to the anchor point? Dreamweaver does show the anchor is in the correct spot (mid-chapter), and I double-checked what I've done so far. Thanks! Last edited by MHC; 12-29-2012 at 06:33 PM. |
12-29-2012, 07:52 PM | #5 | |
Curmudgeon
Posts: 629
Karma: 1623086
Join Date: Jan 2012
Device: iPad, iPhone, Nook Simple Touch
|
Quote:
Book readers act like paged media (e.g. printed pages); element positioning is computed only once when you first open the book, so that page 65 is always page 65. (*) When clicking a link to an anchor, a reader behaves as though you turned to the page containing that anchor using the "next page" button. So if the subheading is halfway down the page, it appears halfway down the page just as it would if you turned to that page in a printed copy of the book. If you want the subhead to be at the top of the page, you would need to insert a page break before the heading to force it to always be at the top of the page. (*) As a special exception, changing the reader's font style/size settings, margin settings, etc. forces the reader to lay out the book's content again. |
|
12-29-2012, 10:14 PM | #6 |
Member
Posts: 10
Karma: 10
Join Date: Feb 2012
Location: Northeast US
Device: iPad 2, old Kindle
|
Good to know, I assumed incorrectly. Thanks for your help everyone!
|
12-30-2012, 03:34 AM | #7 | |
frumious Bandersnatch
Posts: 7,516
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
Quote:
a { color: inherit; text-decoration: none; } works perfectly |
|
12-30-2012, 11:16 PM | #8 |
Curmudgeon
Posts: 629
Karma: 1623086
Join Date: Jan 2012
Device: iPad, iPhone, Nook Simple Touch
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Manually add a TOC entry | p3aul | Sigil | 4 | 06-13-2012 08:22 AM |
TOC Oddity -- Bad Entry For Cover | SteveMB | Conversion | 2 | 01-03-2012 11:09 PM |
2 lines in one toc entry | alansplace | Sigil | 13 | 07-05-2011 06:34 PM |
Unexpected TOC entry | neil_matthews | Conversion | 4 | 06-12-2011 12:45 PM |
Managing HTML Link Behavior, From TOC to Chapter Headings | FlooseMan Dave | Calibre | 1 | 03-31-2010 11:55 PM |