View Full Version : 'apos' error


loraw
10-17-2011, 02:45 PM
Hi,
When I validate my epub file, it gives me an error
ERROR: /OEBPS/content.opf(6): Entity 'apos' is undeclared.

The only place I find 'apos' is in the content.opf file. There is an apostrophe in the title. The code is as follows:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<package xmlns="http://www.idpf.org/2007/opf" xmlns:dc="http://purl.org/dc/elements/1.1/" unique-identifier="bookid" version="2.0">
<metadata>
<meta name="generator" content="Adobe InDesign"/>
<meta name="cover" content="x5150.png"/>
<dc:title>A Country Doctor&apos;s Journal</dc:title>

I changed it to see what would happen to this:
<dc:title>A Country Doctors Journal</dc:title>

However, I'm still getting the same error.

Does anyone know what I'm missing and how to fix it?

Thanks,
lw

loraw
10-17-2011, 04:25 PM
FYI: In case anyone encounters this error, I did get to the bottom of it. In the file info. description I removed the apostrophe form the document title and author title. That solved the problem. I tried changing the code but it still gave me an error. $apos; is valid XHTML, not HTML. I tried HTML code $#39; but I still got an error.

lw

Doitsu
10-17-2011, 05:21 PM
Simply replace $apos; with an actual apostrophe or a typographic apostrophe ( )

Jellby
10-18-2011, 03:58 AM
In the OPF and NCX files you cannot use named entities, anyway.