View Single Post
Old 03-10-2021, 03:22 PM   #29
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: 9,063
Karma: 6361556
Join Date: Nov 2009
Device: many
Do not replace it. That first xmlns is not the same as the xmlns:epub that is needed.

Both should be there. Just add the missing xmlns:epub without removing the default xhtml xmlns attribute. Just like in a blank xhtml page created by Sigil using the BookBrowser.

I have changed Sigil master's Mend to add both under epub3 if they are missing. So using a simple mend will "fix" things.

When these xmlns attributes are used on the html tag, they are inherited by all child tags (ie everyone). When used on lower tag like the nav tag itself, they are limiting them to just that tag and its contents.

Since multiple nav tags exist in the Nav file each would need this duplicated, which is why it is most often just added to the html tag once and done.

KevinH

Quote:
Originally Posted by dynabook View Post
It had the attribute xmlns="http://www.w3.org/1999/xhtml" in the html tag. Replacing that attribute with the suggested one seems to fix the problem.

I have another epub where the landmarks section has:
<nav xmlns:epub="http://www.idpf.org/2007/ops" epub:type="landmarks" hidden="">
and
<html> has xmlns="http://www.w3.org/1999/xhtml"
which does not throw the error.

Anyway error resolved and understanding increased.

--MH

Last edited by KevinH; 03-10-2021 at 03:43 PM.
KevinH is offline   Reply With Quote