View Single Post
Old 11-25-2022, 02:12 PM   #4
Gregg Bell
Gregg Bell
Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.Gregg Bell ought to be getting tired of karma fortunes by now.
 
Gregg Bell's Avatar
 
Posts: 2,266
Karma: 3917598
Join Date: Jan 2013
Location: Itasca, Illinois
Device: Kindle Touch 7, Sony PRS300, Fire HD8 Tablet
Quote:
Originally Posted by KevinH View Post
Q1 Answer I will leave to Doitsu or others.

Q2 Answer: According to epub2 official spec and schemas (very old now) "lang" is not an allowed attribute on the html tag but xml:lang is allowed and is recognized and takes precedence. I think it is safe to ignore those errors as that rule has been relaxed over the years but FC has not changed with that interpretation of the rules.

Q3 Answer: yes marking the language is a good thing in general. And especially true if multiple languages are used in the book.

Q4 Answer: To be safest, both xml:lang and lang should have the same value and the language region should be properly capitalized.

So for epub2 either remove the lang attribute leaving just the xml:lang attribute or keep them (ignoring the errors from FC) and make them all say "en-US" so they match just to be safe.
Fab, Kevin. Thank you very much.

Two more follow-up questions please.

1) Which is optimal, removing the lang attribute or making them all say "en-US"?
2) If I remove the lang attribute, is the below exactly how it should be?

Code:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">
Thanks.

Last edited by Gregg Bell; 11-25-2022 at 02:23 PM. Reason: Additional question.
Gregg Bell is offline   Reply With Quote