View Full Version : Epub validation problem


silentobserver
08-15-2010, 08:13 AM
I converted a .doc file to html and then converted it to epub format through Calibre. Then i ran it through the threepress.org validation but it's not passing it.



It is giving the following errors:


1.ERROR: infernal - Unknown.epub/content.opf(9): date value '2010-08-15T10:52:36.601000+00:00' is not valid, YYYY[-MM[-DD]] expected


2.ERROR: infernal - Unknown.epub/infernal.htm(38): attribute "link" not allowed at this point; ignored


3.ERROR: infernal - Unknown.epub/infernal.htm(38): attribute "vlink" not allowed at this point; ignored


4.ERROR: infernal - Unknown.epub/infernal.htm(42): attribute "lang" not allowed at this point; ignored


5.ERROR: infernal - Unknown.epub/infernal.htm(44): element "p" from namespace "http://www.w3.org/1999/xhtml" not allowed in this context


6.ERROR: infernal - Unknown.epub/infernal.htm(612): attribute "name" not allowed at this point; ignored


ERROR number 4, 5 and 6 are recurring!

Urgent solution required..

charleski
08-15-2010, 09:37 AM
Most of your problems are caused by differences between html and xhtml - epub uses xhtml. The easiest way to convert .doc files is to use Atlantis Word Processor, but it's not free. Alternative free solutions are to use the Open Office plugin that's listed in the sticky or to import the html into Sigil.

1) This is a bug in epubcheck itself, but to resolve it just edit the metadata value for the date entry in the opf file so it fits the YYYY[-MM[-DD]] format.

2) 3) 4) Just remove the offending attributes from the xhtml.

5) Hard to say without seeing the file, but this is commonly caused by p tags being nested. Check the structure of the code.

6) Name attributes are deprecated in <a> tags, use id instead.

Toxaris
08-15-2010, 11:56 AM
The p element could also be a problem of upper- and lowercase mixup between element names.

shall1028
08-16-2010, 01:51 AM
Calibre places an URL in (at least) one of its metadata fields. This causes problems with epub checkers.