Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Development

Notices

Reply
 
Thread Tools Search this Thread
Old 04-05-2021, 11:05 AM   #1
Lafisrap
Junior Member
Lafisrap began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Jul 2020
Device: Kindle Reader
Question EPub works in Amazon KDP but not in Google Play

Code:
Error while parsing file: attribute "class" not allowed here; expected attribute "dir", "lang", "version" or "xml:lang"
I like to publish an ebook created by ebook-convert 4.23.0 on Google PlayStore and their epub validator returns

Code:
Error while parsing file: attribute "class" not allowed here; expected attribute "dir", "lang", "version" or "xml:lang".
for every chapter. I found out removing class attribute from the html tag solves the problem.

Code:
<html xmlns="http://www.w3.org/1999/xhtml" class="calibre">
I also read here: https://bugs.launchpad.net/calibre/+bug/1897582 , that it might be a css attribute assigned to the html element.

But I don't find any style information, that I set on the html element. I just pass in a markdown file with additional CSS set, but this contains nothing for the html tag. And if I omit it, I get the same error.

Is is possible to tell ebook-convert not to add the class somehow?

Here is the command I use:

Code:
ebook-convert /tmp/ebookmaker_tmpfile.epub.md path/to/book.epub --language "de" --title "Booktitle" --authors "Author" --output-profile "kindle" --book-producer "ewer" --comments "MIT" --isbn "9798683069964" --pubdate "<DATE>" --publisher "Michael Schmidt" --extra-css "[path to]/media/global.css" --embed-all-fonts --line-height "22" --change-justification "justify" --formatting-type "markdown" --toc-title "Inhalt" --level1-toc "//h:h2" --use-auto-toc
Any hints appreciated ...
Lafisrap is offline   Reply With Quote
Old 04-05-2021, 11:35 AM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,860
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Dont set any css that applies to the html tag and there wont be a class attribute on it.
kovidgoyal is offline   Reply With Quote
Reply

Tags
markdown epub


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Google Play books, and Amazon Kindle, no possible e-reader? Xygnis General Discussions 6 09-10-2018 08:14 AM
Google Play Books on Amazon Kindle? Valarauko Kindle Developer's Corner 2 10-18-2016 05:54 AM
Google Play vs Amazon: Comparing the Bookstores stonetools General Discussions 1 07-06-2012 03:56 PM
Amazon Matching Google Play With $.49 App Promotion robertc88 Kindle Fire 0 03-09-2012 11:57 AM


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


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