Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 04-17-2021, 03:07 PM   #1
shore_pk
Enthusiast
shore_pk began at the beginning.
 
Posts: 37
Karma: 10
Join Date: Nov 2010
Device: none
Table of Contents question

Is it possible to have this Sigil point to the same page more than one time in the table of contents?

For example:

Table of Contents

ABC Listing:
A
B
C

Listing by topic:
C
A
B

So in other words if I put xhtml pages A, B and C under heading ABC Listing. Can I then put them under Listing by topic but in a different order?

I know I can copy the pages and call them a new name but then if I have to change something on page A I would have to do it in more than one location. If I can someone point to the same page I would only have to make the change one time.

I hope this is clear.

Thank you,

Linda
shore_pk is offline   Reply With Quote
Old 04-17-2021, 03:13 PM   #2
LucyOne
Librocubicularist
LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.LucyOne ought to be getting tired of karma fortunes by now.
 
LucyOne's Avatar
 
Posts: 612
Karma: 11908487
Join Date: Dec 2013
Location: Germany
Device: PocketBook InkPad 3 & Touch HD 3, Kobo Clara HD, Kindle Paperwhite 4
It's possible as the ToC only contains links. Just create another link and have it point to any location you need, even one used before already.
LucyOne is offline   Reply With Quote
Advert
Old 04-17-2021, 03:24 PM   #3
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 5,766
Karma: 3571822
Join Date: Nov 2009
Device: many
That is fine in an HTML toc, but for the NCX epubcheck frowns on two links to the same destination with different play orders. The trick is to add an anchor with an additional id but no txt right before your desired anchor. Now you can havetwo different destination ids that effectively go to the same location.
KevinH is offline   Reply With Quote
Old 04-17-2021, 04:07 PM   #4
shore_pk
Enthusiast
shore_pk began at the beginning.
 
Posts: 37
Karma: 10
Join Date: Nov 2010
Device: none
I am sorry I do not know how to use anchors and ids. Could you point me to instructions or instruct on how to do that?

Thank you! So glad to know there is a way!
shore_pk is offline   Reply With Quote
Old 04-17-2021, 06:19 PM   #5
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 5,766
Karma: 3571822
Join Date: Nov 2009
Device: many
Try using google and search the web for beginners guides to html. I am sure there are many of them. And once you have those down, there are many intermediate and advanced guides that are available as well.

Creating a good epub with Sigil/PageEdit does require a basic knowledge of html and css. Learning those skills are valuable for epub production.

Last edited by KevinH; 04-17-2021 at 06:24 PM.
KevinH is offline   Reply With Quote
Advert
Old 04-17-2021, 10:45 PM   #6
odamizu
just an egg
odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.odamizu ought to be getting tired of karma fortunes by now.
 
odamizu's Avatar
 
Posts: 1,359
Karma: 2238734
Join Date: Mar 2015
Device: Kindle Oasis1 & Voyage, iOS
@shore_pk — I find w3schools.com quite helpful. There are tutorials and reference pages to help you learn html/css.

anchors: https://www.w3schools.com/tags/tag_a.asp

ids: https://www.w3schools.com/html/html_id.asp
odamizu is offline   Reply With Quote
Old 04-18-2021, 04:13 AM   #7
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 1,915
Karma: 8347741
Join Date: Jul 2012
Device: Kobo Forma, Nook
Quote:
Originally Posted by shore_pk View Post
Is it possible to have this Sigil point to the same page more than one time in the table of contents?
Yes, but like KevinH said, there may be a few warnings going off with the EPUB checking tools!

TOCs are very important for ebooks, as it lets the EPUB reader know which order chapters go in + how many "pages" are left while reading.

And 99.9% of the time, duplicates are accidents.

(I'll explain further below.)

Quote:
Originally Posted by shore_pk View Post
Table of Contents

ABC Listing:
A
B
C

Listing by topic:
C
A
B

So in other words if I put xhtml pages A, B and C under heading ABC Listing. Can I then put them under Listing by topic but in a different order?
What is the goal here?

Are you creating a list of recipes by category+main-ingredient? A list of poems by year+author?

Perhaps there'll be an alternate way to organize or some other solution.

Quote:
Originally Posted by KevinH View Post
The trick is to add an anchor with an additional id but no txt right before your desired anchor. Now you can havetwo different destination ids that effectively go to the same location.
And this is the way you would do that:

Before:

Chapter01.xhtml:

Code:
<body>
<h2>Chapter 1</h2>
<p>There once was a time before time [...].</p>
TOC.xhtml:

Code:
<h2>Table of Contents</h2>
<p class="toc"><a href="../Text/Chapter01.xhtml">Chapter 1</a></p>
<p class="toc"><a href="../Text/Chapter02.xhtml">Chapter 2</a></p>
<p class="toc"><a href="../Text/Chapter03.xhtml">Chapter 3</a></p>
[...]
<h2>Alternate Table of Contents</h2>
<p class="toc"><a href="../Text/Chapter03.xhtml">Chapter 3</a></p>  <--- Duplicate Warning
<p class="toc"><a href="../Text/Chapter02.xhtml">Chapter 2</a></p>  <--- Duplicate Warning
<p class="toc"><a href="../Text/Chapter01.xhtml">Chapter 1</a></p>  <--- Duplicate Warning
After:

You'd want to add an "id" in your anchor, like KevinH suggested:

Chapter01.xhtml:

Code:
<body>
<h2 id="Chapter01">Chapter 1</h2>
<p>There once was a time before [...].</p>
Do you see that part in red? That's an id.

It doesn't do anything by itself, but...

You can tell a link to jump to that exact location by using a special symbol: #:

TOC.xhtml:

Code:
<h2>Table of Contents</h2>
<p class="toc"><a href="../Text/Chapter01.xhtml">Chapter 1</a></p>
<p class="toc"><a href="../Text/Chapter02.xhtml">Chapter 2</a></p>
<p class="toc"><a href="../Text/Chapter03.xhtml">Chapter 3</a></p>
[...]
<h2>Alternate Table of Contents</h2>
<p class="toc"><a href="../Text/Chapter03.xhtml">Chapter 3</a></p>  <--- Duplicate Warning
<p class="toc"><a href="../Text/Chapter02.xhtml">Chapter 2</a></p>  <--- Duplicate Warning
<p class="toc"><a href="../Text/Chapter01.xhtml#Chapter01">Chapter 1</a></p>
So let's break down that 1st link:

Code:
<a href="../Text/Chapter01.xhtml">
This is saying:
  • "Jump to a file called Chapter01.xhtml".

And the 2nd link:

Code:
<a href="../Text/Chapter01.xhtml#Chapter01">
is saying two things:
  • "Jump to a file called Chapter01.xhtml"
  • "and jump to the location of the id called Chapter01" (red part)

That id just so happens to exist at the tippy top of the file as well, so they act nearly the same when the reader clicks on them.

Anyway, this would get rid of your little warnings... but as I said above, there may be a much better solution out there.

Last edited by Tex2002ans; 04-18-2021 at 04:23 AM.
Tex2002ans is online now   Reply With Quote
Old 04-19-2021, 11:39 AM   #8
shore_pk
Enthusiast
shore_pk began at the beginning.
 
Posts: 37
Karma: 10
Join Date: Nov 2010
Device: none
Ok. Ty. I will see what I can come up with later today!
shore_pk is offline   Reply With Quote
Old 04-19-2021, 12:23 PM   #9
shore_pk
Enthusiast
shore_pk began at the beginning.
 
Posts: 37
Karma: 10
Join Date: Nov 2010
Device: none
I am trying to make a book that is a collection of booklists and reviews. I need all of them listed alphabetically, the historical books listed chronologically and the science and nature books listed alphabetically. I have around 80 listings and will have more in the future. Instead of the toc having so many listings it will have these three (plus a few others that are for other things in the book).

I think I will just create 3 pages that have all of the listings on each page in the order I want them. I think this will keep it cleaner in the toc and also easier for me to.

Is there a way to have page numbers in Sigil? I couldn't find one but would like to as I'm going to print a copy of the book. I would also want to put the page number with each hyperlinked listing on each of the 80 listings, if possible.

Thanks again!
shore_pk is offline   Reply With Quote
Old 04-19-2021, 12:30 PM   #10
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 5,766
Karma: 3571822
Join Date: Nov 2009
Device: many
Create an index
KevinH is offline   Reply With Quote
Old 04-19-2021, 01:04 PM   #11
shore_pk
Enthusiast
shore_pk began at the beginning.
 
Posts: 37
Karma: 10
Join Date: Nov 2010
Device: none
Ah! Thank you!
shore_pk is offline   Reply With Quote
Old 04-19-2021, 02:23 PM   #12
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 1,915
Karma: 8347741
Join Date: Jul 2012
Device: Kobo Forma, Nook
Quote:
Originally Posted by shore_pk View Post
I am trying to make a book that is a collection of booklists and reviews. I need all of them listed alphabetically, the historical books listed chronologically and the science and nature books listed alphabetically. I have around 80 listings and will have more in the future. [...]
Split it into 3 separate TOC files:

- Table of Contents
- Alphabetical
- Chronological

* * *

Tip: In your actual HTML files, be sure to use proper headings:

Code:
<h1>Part 1: Animals Doing Wacky Things</h1>
<h2>Chapter 1: The Cow Jumps</h2>
<h3>1.1. Over the Moon</h3>
<h3>1.2. Over the Barn</h3>
This allows you to use Sigil's Tools > Table of Contents > Generate Table of Contents to create/update the main TOC files at the press of a button.

From there, you'd have to manually recreate the Alphabetical/Chronological versions:

Table of Contents
(This needs to be in your "actual reading order", like in a physical book, "from Page 1->99".)

Code:
<h2>Table of Contents</h2>
<p class="toc"><a href="../Text/Chapter01.xhtml">1. The Journey</a></p>
<p class="toc"><a href="../Text/Chapter02.xhtml">2. Begins</a></p>
<p class="toc"><a href="../Text/Chapter03.xhtml">3. Here</a></p>
Alphabetical

Code:
<h2>Alphabetical</h2>

<h3>B Stories</h3>
<p class="toc"><a href="../Text/Chapter02.xhtml">2. Begins</a></p>

<h3>H Stories</h3>
<p class="toc"><a href="../Text/Chapter03.xhtml">3. Here</a></p>

<h3>T Stories</h3>
<p class="toc"><a href="../Text/Chapter01.xhtml">1. The Journey</a></p>
Chronological

Code:
<h2>Chronological</h2>

<h3>2000 Stories</h3>
<p class="toc"><a href="../Text/Chapter03.xhtml">3. Here</a></p>

<h3>2001 Stories</h3>
<p class="toc"><a href="../Text/Chapter01.xhtml">1. The Journey</a></p>

<h3>2002 Stories</h3>
<p class="toc"><a href="../Text/Chapter02.xhtml">2. Begins</a></p>
Then you could use the simple links in every single case, and readers can use whichever TOC is the most helpful for their needs.

Quote:
Originally Posted by shore_pk View Post
Is there a way to have page numbers in Sigil?
... there's no such thing as "pages" in ebooks.

All you'll need to do is link to the correct chapter/subchapter.

Quote:
Originally Posted by shore_pk View Post
I would also want to put the page number with each hyperlinked listing on each of the 80 listings, if possible.
No. Don't do it. This is a very bad idea.

Quote:
Originally Posted by shore_pk View Post
I couldn't find one but would like to as I'm going to print a copy of the book.
The Print and Ebook are separate things.

In the Print book, yes, include page numbers in the TOC + headers/footers.

But in the Ebook, that stuff doesn't belong, because there's no such thing as page #s!

Side Note: Over the years, there's been TONS of discussion about this... and a similar idea comes up from "geniuses" who decide to leave the physical book's page numbers smack dab in the middle of text:

Code:
<p>This is a very long sentence that</p>

<p>199</p>

<p>is split between two pages.</p>
NO! And that will get you dinged by Amazon + other stores as readers report errors.

Last edited by Tex2002ans; 04-19-2021 at 02:39 PM.
Tex2002ans is online now   Reply With Quote
Old 04-21-2021, 10:50 AM   #13
Notjohn
mostly an observer
Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.
 
Posts: 1,471
Karma: 987654
Join Date: Dec 2012
Device: Kindle
For a print edition, upload a right-sized, error-free PDF, with any images at 300 dots per inch. To look like a trade paperback, choose 5.5x8.5 inches if it's under 300 pages, though you might go to 6x9 if it's longer. 12 point type is best; 11 point if you're really trying to squeeze. (This isn't a mass-market paperback on a revolving rack at the drugstore!)

Choose mirrored pages, margins a minimum of 0.5 inch on the three outside edges, with a gutter (inside edge) 0.8 - 1.0 inch depending on the number of pages from 100 to 400. Spend a LOT of time getting it right. You can do this in Word, though I actually prefer OpenOffice Writer for the final tweaking and outputting the PDF.

I don't use headers, so as to avoid the tradition (which I respect) that there should be no headers or footers on any page in the front matter, that begins a chapter, or that is blank or has a full-page image. Rather I center the page number in the footer, which falls outside the bottom margin, but 0.5 inch is enough to avoid trespassing on the no-go zone.

Get a physical proof copy if you possibly can and spend a LOT of time examining it.
Notjohn is offline   Reply With Quote
Old 04-22-2021, 10:31 PM   #14
AlanHK
Fanatic
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 597
Karma: 300000
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by Tex2002ans View Post
But in the Ebook, that stuff doesn't belong, because there's no such thing as page #s!

Side Note: Over the years, there's been TONS of discussion about this... and a similar idea comes up from "geniuses" who decide to leave the physical book's page numbers smack dab in the middle of text:

Code:
<p>This is a very long sentence that</p>
<p>199</p>
<p>is split between two pages.</p>
When it's visible I assume it's from a careless conversion from print or OCR. Never thought anyone would deliberately do that.

However, you can embed the physical page numbers as anchors, and then an index links to that.

e.g. the index has entries like this:
Code:
<li class="indexmain" id="idx1_34"><span epub:type="index-term">Apollo program,</span> <a epub:type="index-locator" href="../Text/ch50.xhtml#page_417">417</a></li>
that linked to text coded like:
Code:
“Every day felt a bit like a roller coaster, where we <span aria-label="page 417" epub:type="pagebreak" id="page_417" role="doc-pagebreak"></span>discovered a new problem
making an invisible anchor for the beginning of that page.

If DIY, can use simpler anchors like
Code:
<a id="page_417"></a>
The advantage is that the text of the index is the same as the print version.

Last edited by AlanHK; 04-22-2021 at 10:43 PM.
AlanHK is offline   Reply With Quote
Old 04-23-2021, 12:49 AM   #15
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 1,915
Karma: 8347741
Join Date: Jul 2012
Device: Kobo Forma, Nook
Quote:
Originally Posted by AlanHK View Post
When it's visible I assume it's from a careless conversion from print or OCR. Never thought anyone would deliberately do that.
You must've missed the famous 2016 thread: "Real Page Numbers for Reflowable Kindles"!
Tex2002ans is online now   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Touch Question about Table of Contents and STR apastuszak Barnes & Noble NOOK 4 06-30-2011 08:13 AM
Table Of Contents Question Humble Calibre 2 07-26-2010 09:10 PM
Question Regarding Table of Contents Guns4Hire Sigil 2 01-12-2010 11:15 PM
Table of contents and time question lizzielou Sony Reader 2 11-29-2009 04:48 AM


All times are GMT -4. The time now is 03:17 PM.


MobileRead.com is a privately owned, operated and funded community.