First, I wanted to point out KevinH's Sigil Plugin,
"Access-Aide".
It helps fill blank <title>s (using the first heading in the document) + add lang + xml:lang to your <html>.
Quote:
Originally Posted by Gregg Bell
1) How come some of the chapters in my novels in Sigil have the book title in the title tags on every file and others don't? (I've made them identically and not manually added anything to the title tags.)
|
Did you convert using Calibre or something else?
Sometimes the tools put gibberish in the <title> (like InDesign puts the filenames... you can safely delete those):
Code:
<title>Chapter_1.xhtml</title>
<title>abc123456890_book_EPUB.epub</title>
Sometimes tools will put some info (like Book Title, Chapter Title, Author, [...]):
Code:
<title>Gregg Bell - Dupes-A-Navy: Chapter 1</title>
Quote:
Originally Posted by Gregg Bell
Does it matter if the title is in those chapter files?
|
It doesn't hurt if it's blank, but it could be helpful IF there is meaningful info in the <title>.
Something like:
Code:
<head>
<title>Chapter One: The Beginning</title>
<link href="../Styles/stylesheet.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<h2>Chapter One: The Beginning</h2>
would be helpful for Accessibility reasons:
- If that HTML gets opened up in a browser, the <title> is what shows in the tab.
- If being read by a screenreader, the person may have the <title> spoken out loud.
- Some ereaders might display that as the header/footer (don't know of any that do).
Technical Side Note: WCAG has a few articles on how to create good <title>s:
G88: Providing descriptive titles for Web pages
H25: Providing a title using the title element
Understanding SC 2.4.2
For example, G88 gives this reasoning/recommendation for good <title>s:
Quote:
Originally Posted by Gregg Bell
2) I have removed the language ending of that tag that begins <html xmlns... and I have also removed the language stuff from the <body> tag. Is this okay the way I have it?
|
Again, having the
lang +
xml:lang there doesn't hurt.
An EPUB Reader should be able to still pull the book's language from the EPUB's Metadata (
Tools > Metadata Editor), and grab your
dc:language (in your case, "en" (English) or "en-US" (English (United States)).
BUT, again, think screen reader or someone converting to a different format. They may pull the HTML out separately and read it elsewhere.
So you may want to add the
lang +
xml:lang to your HTML as well.
This doesn't hurt:
Code:
<html xmlns="http://www.w3.org/1999/xhtml">
but this could be made more helpful:
Code:
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
Another way of explaining: The EPUB Metadata tells the reader "This EPUB is in US English", while the HTML tells the reader "This specific HTML page is in US English".
(Imagine there could be a US English book, but it has a British English chapter within it.)
Technical Side Note:
H57: Using language attributes on the html element
H57 explains why
lang +
xml:lang on <html> are important:
So it could help:
- Braille conversion
- TTS
- Dictionary support
- Automatic Translation
- Spellchecking
- Calibre has Multi-Language Spellchecking
- Hyphenation
- [...]
Again, an EPUB Reader SHOULD still be able to pull it from the EPUB Metadata... but not all tools will be reading your EPUB in EPUB. :P