Skip to main content
Inspiring
May 19, 2018
Answered

InDesign or with html how can I create a table of contents, which has an arrow to see all the subtitles of a chapter?

  • May 19, 2018
  • 2 replies
  • 1897 views

I have a summary with chapters and these also have subtitles. I want if I see the summary in the eBook the first time, I only see the chapters with the arrow next to it and not all the subtitles listed. How you do it? Look at the photo:

This topic has been closed for replies.
Correct answer Yves Apel

I have a book in German “ePub für InDesigner“ (ePub for InDesign). I read it for to learn how I can create an eBook. Chapter 6.3 is exactly the chapter hoe explains how to create table of contents. When I had all chapters, cover and table of contents I did in InDesign Menu File > New > Book I got my first eBook in ePub-Format. It is ePub 2.0.1, but I have the possibility to put it on ePub 3. But the book contains so much of text, 5 small pictures in black and white, no grey, one table, I thought it will be enough. It is an out-of-print book, without video or music.

May be my English is not very good. When I wrote I did the nested lists “long time ago”, I wanted to say I did it two or three weeks ago, before my question in this forum. And yes the code I send you miss an </ul> in the end. The error was because I only copied part of the code. And I never touched the toc list. Sorry ;-)

And because <ol> and not <ul>? Why I have to use an ordered list and not an unordered? The first chapter is the file number 9! I wanted to copy the book as accurately as possible and the table of contents has no numbers and so I chose <ul> instead of <ol>.

You mean If I make nested list like this, it will be enough?:

<ol>

<li><a href=”Chapter_1.xhtml”>Chapter 1</a>

<ol>

<li><a href=”Subtitle_1.xhtml”>Subtitle 1</a></li>

<li><a href=”Subtitle_2.xhtml”>Subtitle 2</a></li>

<li><a href=”Subtitle_3.xhtml”>Subtitle 3</a></li>

</ol>

</li>

</ol>


I have a book in German “ePub für InDesigner“ (ePub for InDesign). I read it for to learn how I can create an eBook.

Yes, I know this book very well. I wrote half of it, exactly 6 years ago! It contains screenshots in colour as well as the code examples, where needed. It did not make sense to include much tables (to show what?). At this time also printed books rarely had videos included and I assure you that you do not want to hear the music I might produce

This 6 years make a great difference and the book is not really up to date anymore. At the point where this book has been written, InDesign CS5/5.5 has been in the early stages of ePub creation and even ePub itself was early stage (standard not completely defined) and also Sigil was different. Even if ePub 3 has been released in oct. 2011, it still has to find its way today (a lot of publishers still stick with ePub 2, but this is another discussion).

There have been many, many things which evaluated and changed in the meantime (in InDesign, for ePub and also with Sigil). Please don't ask, to mention these differences here. This would be out of scope. But let me give you one more tip. Do not convert ePub 2 to ePub 3 before you don't have a lot of experience with both versions and do not use Sigil (anymore) to convert them from v2 to v3 if the ePubs have been created originally with InDesign. The results might end up with unexpectet, hard to correct results.

You can take a look at lynda.com. They have more recent tutorial videos about ePub creation. But, I don't know if they go in depth with HTML/CSS as well as explaining the standard in detail. The Book can still be used, but you need InDesign CS5.5 and you might stick with ePub 2 to get the correct results.

And because <ol> and not <ul>? Why I have to use an ordered list and not an unordered?

Because the IDPF defined it this way for ePub. You can read more about here​. Even if ePub is HTML and CSS, they have their differences on how to use this markup. You can't create an ePub in the same way, you create things for websites.

2 replies

Inspiring
May 22, 2018

The example Screenshot you have shown looks very familiar and taking a look into this book from this screenshot explains how to create hierarchies in the table of contents (see chapter 6.3 – Inhaltsverzeichnis hinzufügen -> Inhaltsverzeichnis erstellen).

You can get these arrows by setting a different level in the TOC settings in InDesign. Looking at the screenshot, titles such as "[Haupttitel]" are Level 1. Titles such as "Aufbau des Buches" are Level 2.

pfudiAuthor
Inspiring
May 22, 2018

Thank you very much for answer.

I did like the screenshot, I did ti like a list. Ul = level 1, then for level 2 I have a class in CSS .ul-rientro.

<h1>Inhaltsverzeichnis</h1>

<uk> Chapter 1</ul>

<ul class="ul-rientro">

<li>Subtitle 1</li>

<li>Subtitle 2</il></ul>....

I did it I don't remember how times I did it and it's not working. Whats woring?

Inspiring
May 22, 2018

Should be automatically managed when using InDesign.

BobLevine
Community Expert
Community Expert
May 19, 2018

Please define eBook. It is a catch-all phrase which is virtually meaningless.

pfudiAuthor
Inspiring
May 19, 2018

I copied an out-of-print book. In InDesign, I made a new file for each chapter, cover, and table of contents. Menu File> New> Book I made a book in ePub format. This works well in Adobe Digital Editions. With Sigil I have improved various, including the hyperlinks in the table of contents.

Steve Werner
Community Expert
Community Expert
May 19, 2018

Moving to InDesign EPUB forum