Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 01-07-2015, 07:38 PM   #1
JoseWriter
Member
JoseWriter began at the beginning.
 
Posts: 11
Karma: 10
Join Date: Sep 2011
Device: Nook, Kindle, iPad
Red face epub 3.0 validation: The a element must no appear inside a elements

I have created a multimedia epub 3.0 ebook intended for upload to ibooks. The ebook is large (63.8mb) due to the audio/video and hundreds of images. Also there is a large index at the end with links to the ebook text containing over 1,300 internal hyperlinks in the index.

I have only one epubcheck validation error, but it is driving me insane. The error message is: ERROR: mybookname v36CC.epub/OEBPS/mybookname-multimedia-v36CC-50.xhtml(30,228): report: The a element must not appear inside a elements.

I have gone through this code dozens of times and cannot find where i have overlapping elements. I attached a txt file with the code, in hopes someone can help. Thanks!
JoseWriter is offline   Reply With Quote
Old 01-07-2015, 11:51 PM   #2
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
I don't see the text file...
eschwartz is offline   Reply With Quote
Advert
Old 01-08-2015, 11:52 AM   #3
JoseWriter
Member
JoseWriter began at the beginning.
 
Posts: 11
Karma: 10
Join Date: Sep 2011
Device: Nook, Kindle, iPad
I attached the text file but somehow messed it up. I've not attached files before. I am pasting the code for the offending page below. From the error code, it seems line 30 is where the problem is at offset 228 but I could find no problem anywhere in that line. The file includes text anchors for the many hyperlinks in the index.

<?xml version="1.0" encoding="utf-8" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops">
<head>
<title>Move-Your-stuff-multimedia-v36CC-50</title>
<link href="../Styles/idGeneratedStyles.css" rel="stylesheet" type="text/css" />
<link href="../Styles/CSS_Override.css" rel="stylesheet" type="text/css" />
</head>

<body id="Move-Your-stuff-multimedia-v36CC" xml:lang="en-US">
<div>
<p class="Page-Break ParaOverride-7">&nbsp;</p>

<p class="JR-Picture-Centered"><img alt="" class="_idGenPageitem-27" src="../Images/Figure37.jpg" /></p>

<p class="JR-Caption-1--Callouta-and-Special-">Skills and Knowledge location in bagua.</p>

<p class="JR-Figure--Callouta-and-Special-">FIGURE 37</p>

<p class="JR-H3-Tools-Right-Justified"><span class="Heading--10---Spacing--1-pt"><a id="skills-knowdlege-powertools-163"></a><a id="Anchor-119"></a><a id="x.3713"></a></span> <span class="JR-Bold _idGenCharOverride-3">Power Tools</span> for Skills and Knowledge<img alt="" class="_idGenPageitem-12" src="../Images/Powertool2.png" /></p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1"><a id="Earth-Element-skills-163"></a><a id="x.3716"></a>Earth <a id="skills-Element"></a><a id="x.3719"></a>Element</span><span class="Body-text--20----Constantia _idGenCharOverride-9">&nbsp;&nbsp;&nbsp;</span>Flat and square shapes, yellow and <a id="x.3722"></a><a id="earth-tone-skills"></a>earthy colors, items made from clay, stones, sand, and dirt in potted plants are the things this area loves.</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1"><a id="Blue-163"></a><a id="x.3726"></a>Blue</span><span class="Body-text--20----Constantia _idGenCharOverride-9">&nbsp;&nbsp;&nbsp;<a id="skills-colors-163-Blue"></a><a id="x.3729"></a></span>Blue is the color for this part of the bagua, so just about anything blue will do. Cramming for finals? Hang your blue jeans in the corner to get a better grade. Viagra is a little blue pill. Blue is for <span class="JR-Italics _idGenCharOverride-1">skills</span> and knowledge. Hmmm...</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1"><a id="Books-163"></a><a id="x.3732"></a>Books</span><span class="Body-text--20----Constantia _idGenCharOverride-9">&nbsp;&nbsp;&nbsp;</span>Even though they are considered wood element, which is uprooting to this area’s earth element, books are welcome in the Skills and Knowledge area for “symbolic of wisdom” reasons. Use a few or all you’ve got. Even if this area falls in your garage, set up a little spot to display stuff that helps you get wise. Use bookends that symbolize a skill of yours, or a skill that you would like to master. A friend of mine has his books held up by blue polished geode bookends. He’s into geology among other things.</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1">Light</span><span class="Body-text--20----Constantia _idGenCharOverride-9">&nbsp;&nbsp;&nbsp;<a id="Light-162v2"></a></span>Light is one of those traditional cures that can energize just about anything. But used here in the Skills and Knowledge section, it can be especially meaningful. Any light works great— lamps with light bulbs, lanterns, candles. Heck, just a light bulb with proper intent can do the trick. The sayings “Shed some light on the subject” and “Gain enlightenment” hint that light helps with knowledge and intelligence. If you are using a lamp, remember—as long as it is plugged in and works, it will do. It does not have to be on for good feng shui.</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1"><a id="Food-164"></a><a id="x.3738"></a>Food</span><span class="Body-text--20----Constantia _idGenCharOverride-9">&nbsp;&nbsp;&nbsp;</span>If your kitchen is in this corner of your home, intend that all the food you buy become food for thought. (Who would have thought Cap’n Crunch and lamb chops could be so useful?)</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold CharOverride-14">Things That Remind You of Wisdom&nbsp;&nbsp;&nbsp;</span>A replica of Rodin’s <span class="JR-Italics _idGenCharOverride-1">The Thinker</span>; a lamp of knowledge, the scales of justice, a judges gavel, a chess game, a straight-A report card, and those cute, intelligent dolphins all make great ch’i enhancers. If you think higher thoughts with something, put it here.</p>

<p class="JR-First-Paragraph--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1"><a id="Symbols-objects-skills-164"></a><a id="x.3741"></a>Symbols of Mentors or Wise People&nbsp;&nbsp;&nbsp;</span>A statue of Solomon would make a great symbol of wisdom. He was the guy in the Bible that, when God asked him what he wanted, responded, “Wisdom.” He knew that if he had wisdom he could get the other stuff—money, land, health, and anything else he needed.</p>

<p class="JR-Regular-b4-break--Text-Paragraphs-">You can also use the three Wise Men (even if it’s not Christmas), Merlin the magician, Yoda, Ben (Obi-Wan) Kenobi, Einstein, or Gandhi depicted in statues, pictures, posters, or toys.</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1">Sharp <a id="Metal-skills-knowledge-164"></a><a id="x.3745"></a>Metal&nbsp;</span>“Sharp as a tack” and “razor-sharp mind” help illustrate how sharp metal can suggest a sharp mind. As for other symbolic metal items, give the “one-cent cure” a try. It has Lincoln on it, who is known for his intelligence and wisdom. “A penny for your thoughts!” Save your pennies here and see what thoughts come of it.</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold CharOverride-14">Meditation Items</span><span class="Body-text--20----Constantia CharOverride-34">&nbsp;&nbsp;&nbsp;</span>If you find your wisdom by meditating, this area of the home will yield the best insights. Create a quiet retreat using your bench, chair, or pillows.</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1"><a id="Altars-of-Thanksgiving-165"></a><a id="x.3748"></a>Altars of Thanksgiving&nbsp;&nbsp;&nbsp;</span>Creating a small place in this gua to remind you of all the things you have to be thankful for can add to your wisdom and awareness.</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1"><a id="Symbols-skills-165"></a><a id="x.3751"></a>Symbols</span> <span class="JR-Bold CharOverride-14">of the Skills or Knowledge You Want to Have&nbsp;&nbsp;&nbsp;&nbsp;</span>College students, put things here that symbolize your major. (And while you’re working on this, consider removing the collection of beer bottles from around the world.) Hobbyists, work your craft here.</p>

<p class="JR-H3-Tools-Right-Justified"><a id="skills-Hazardous-165"></a><a id="Anchor-120"></a><a id="x.3754"></a>Hazardous Materials for Skills and Knowledge<img alt="" class="_idGenPageitem-12" src="../Images/Hazard2.png" /></p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1"><a id="elements-Wood-165"></a><a id="x.3758"></a>Wood Element</span><span class="JR-Bold CharOverride-14">&nbsp;&nbsp;&nbsp;</span>Wood uproots your wisdom, so keep things like trees, <a id="columnar-165"></a><a id="x.3761"></a>columnar shapes, <a id="greens-skills--165"></a><a id="x.3764"></a>greens, and plants to a minimum here.</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1"><a id="skills-Clutter-165"></a></span><a href="#skills-Clutter-165"></a><a id="x.3767"></a>Clutter<span class="JR-Bold _idGenCharOverride-1">&nbsp;&nbsp;&nbsp;</span>Thinking clearly requires a <a id="clutter-skills-165-clear"></a><a id="x.3770"></a>clear space. Don’t clutter your mind with unnecessary stuff in your living quarters . . . and yes, I mean the whole house.</p>

<p class="JR-First-Paragraph--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1">Things That Stop the Thought Process&nbsp;</span><span class="Body-text--20----Constantia _idGenCharOverride-9">&nbsp;&nbsp;<a id="x.3773"></a><a id="Alcohol-165"></a></span>Alcohol, <a id="drugs-165"></a><a id="x.3777"></a>drugs, <a id="poisons-165"></a><a id="x.3780"></a>poisons, and <a id="cigarettes-165"></a><a id="x.3783"></a>cigarettes all cloud the thought process and should be kept away from here. If you happen to have a bar in this area of your home, balance it out by having some healthy choices to offer guests—perhaps a juice bar and alcohol bar combo. Sorry about those cigs, smokers, but it really is not too wise to smoke, even if it makes you relax so you can think.</p>

<p class="JR-Regular-b4-break--Text-Paragraphs-">Remember, you have to do your part. Feng shui will only meet you halfway. If you get bombed every night and blow off your job or homework, all the gua embellishing in the world isn’t going to lead you to wisdom or happiness.</p>

<p class="BR-First-Paragraph-b4-Brk--Text-Paragraphs-"><span class="JR-Bold _idGenCharOverride-1">Unwise Symbols&nbsp;</span> Be careful with the <a id="newspaper-166"></a><a id="x.3786"></a>newspaper—it is chock full of stupid people and stupid things (corruption, murder, fires, bankruptcies), things you don’t want to invite into your life. Mike Tyson, Bill Clinton or Monica Lewinsky, River Phoenix, Robert Downey Jr., or anyone else who has done something stupid or just doesn’t get it needs to stay out of this zone.</p>

<p class="JR-H3-Centered-Subheading--Headings-" id="_idParaDest-97"><span class="JR-Bold _idGenCharOverride-3"><a id="Anchor-121"></a>| Left Your Brain in the <a id="Garage-skills-166"></a><a id="x.3790"></a>Garage</span><span class="JR-Bold _idGenCharOverride-3">? |</span></p>

<p class="JR-First-Paragraph--Text-Paragraphs-">In a lot of <a id="homes-garage-166"></a><a id="x.3793"></a>homes, the Skills and Knowledge or Helpful People area of the house falls in the <a id="skills-garage-166"></a><a id="x.3796"></a>garage. As much as some people hope that their garage is not a part of their home, if it lies behind the plane of the front door, it is (see Figure 38). Now, don’t go running off to sue your architect or builder yet. Most are oblivious to feng shui. I’m sure they didn’t do it intentionally. (Support the feng shui cause—give an architect a copy of this book!)</p>

<p class="JR-REgular--Text-Paragraphs-">Garages have an unusual energy about them. Either they have very fast energy whirling about from vehicles coming and going, or they are so crammed with junk that the cars don’t fit, and the energy has come to a grinding, stagnating halt. Either way, the energy is not suitable for comfortable living.</p>

<p class="JR-Regular-b4-break--Text-Paragraphs-">Here’s what you can do about it:</p>

<ol>
<li class="JR-Numbered-List--Bullets-and-Lists- ParaOverride-13" value="1">Cut the crap. You’ve got to take a stand against storing stuff you simply don’t use very often. The more <a id="clutter-skills-166"></a><a id="x.3799"></a>clutter you have, the more brainpower you use subconsciously keeping track of it. Clear the clutter and you clear your mind. I will give a generous exception to the following if they are carefully organized and not overdone: holiday decorations (unless it’s scary, bloody Halloween gunk); children’s clothing and toys (if you are waiting for a younger sibling to grow into them); and papers (the ones the IRS makes you keep for so many years).</li>

<li class="JR-Numbered-List--Bullets-and-Lists- ParaOverride-13">And after you have the crap out, clean the garage as if it is a room in the house. Sweep the floors and dust away the spider webs.</li>
</ol>
</div>
</body>
</html>
JoseWriter is offline   Reply With Quote
Old 01-08-2015, 12:03 PM   #4
odedta
Addict
odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.
 
Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
Holy **** this code needs clean up :P

I couldn't reproduce your error, when I put your code in a validated ePub I get the following error:
Quote:
ERROR: 1.epub/Text/1.html: Obsolete or irregular DOCTYPE statement. External DTD entities are not allowed. Use '<!DOCTYPE html>' instead.
When I fix that to <!DOCTYPE html>I get:
Quote:
ERROR: 1.epub/Text/1.html(13,44): The entity "nbsp" was referenced, but not declared.
ERROR: 1.epub/Text/1.html: The entity "nbsp" was referenced, but not declared.
I guess something else is wrong with your ePub and it's causing the validator to malfunction. This is why I love Calibre, it fixes all your files with a click of a button and can arrange them into folders, its functions saves you this kind of problems.
odedta is offline   Reply With Quote
Old 01-09-2015, 12:44 PM   #5
JoseWriter
Member
JoseWriter began at the beginning.
 
Posts: 11
Karma: 10
Join Date: Sep 2011
Device: Nook, Kindle, iPad
Odedta,

thank you for the swift reply. The code is ugly as it was generated out of Indesign CC, where the original print version of the book was created, so it uses all of the fonts, styles, etc that were used in the print version. It is my understanding that Indesign CC adds the code to allow the ebook to retain its embedded fonts in the iBooks application. I haven't gotten to the Itunes Producer stage yet so I don't know that for sure, I am still trying to get out of epubcheck. This is a large ebook, with over 1,300 text anchors for the index at the back. I am wondering if there is a limit to the number of text anchors or hyperlinks within an epub 3.0?

I used to use Calibre but somewhere along the line I heard that iBooks won't accept ebooks done in Calibre, anyone know if that is still the case? I use Sigil to make my adjustments.

Jose
JoseWriter is offline   Reply With Quote
Advert
Old 01-09-2015, 01:08 PM   #6
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 73,645
Karma: 127837858
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
WOW! That is some awful code. I suggest a thorough hand cleaning of the mess that is that code. Also, whatever program you used that made that code, delete and never use again.
JSWolf is offline   Reply With Quote
Old 01-09-2015, 03:51 PM   #7
JoseWriter
Member
JoseWriter began at the beginning.
 
Posts: 11
Karma: 10
Join Date: Sep 2011
Device: Nook, Kindle, iPad
Dear all,

I have resolved the problem. I decided, after a bit of research, that a lot of the tools out there are not too good when it comes to epub 3.0 and apparently some of them (e.g. Sigil) are not keeping up. Calibre apparently isn't completely 3.0 safe either. I found a tool called Oxygen Author, downloaded a trial subscription, and it immediately took me to the exact spot on the file that needed fixing, and flagged the epub validation errors "LIVE" as I made corrections. I saved the corrected, cleaned up file, and it passed epub 3.o validation.

If anyone is interested in Oxygen, here is a link for a trial http://www.oxygenxml.com/download_oxygenxml_author.html

I do want to say one other thing. I appreciate the replies I received, and I am sorry about the ugly code. I am not an epub expert, I don't write original code...what I do is publish books using Indesign and other tools, and then translate them to ebooks for the authors. I need the easiest, simplest, quickest way to do that, and so I use tools that can generate some damn ugly code. My sincere apologies. But perhaps in my fumbling around, I have been able to help other newbies who, like me, are not purists and just want to get the job done. My thanks to all, I appreciate you very much.

Jose
JoseWriter is offline   Reply With Quote
Old 01-09-2015, 04:53 PM   #8
radiocure
Member
radiocure began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Jul 2011
Device: none
Yeah, the big takeaway from this is that if you open an epub3 book in Sigil, it will ruin the book completely. You can export to reflowable from InDesign CC and use that file in Sigil if you must, but again, you'll find that the code ends up awfully bloated.
radiocure is offline   Reply With Quote
Old 01-09-2015, 04:59 PM   #9
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Well, there is some work being done on Sigil, at the moment, it just isn't ready yet. Also, there is an experimental EPUB3 output plugin, which I believe fixes the packaging as Sigil already forgives the presence of multimedia.
EPUB3 is still treated with much skepticism outside the limited field of fixed-format and/or multimedia, so it is difficult to get people willing to work on support.

calibre works just fine, at least, the editor component will handle EPUB3 just fine depending on how you use it. The important thing to realize is that it is no different than Sigil in editing the raw HTML, although it has a slightly different set of tools.
It is true that calibre conversion will produce blended (think food processor) ebooks, meant for end-users. And often these will be rejected by stores.
The editor is a recent creation, far more recent than the lore that says stores reject anything that calibre touched.

calibre's Edit Book might be worth taking a look at, you may wish to add it to your tools(, or you might decide you prefer Sigil).


Glad you found something that helps you although it is worth keeping in mind that learning the ins and outs of HTML+CSS (at least, the subset used in EPUB) is a useful long-term goal for anyone who will be working in the ebook field. It can save you a lot of bother in figuring out why something doesn't work.
You don't have to be an expert, but having familiarity can save time in the end.
eschwartz is offline   Reply With Quote
Old 01-10-2015, 03:54 AM   #10
odedta
Addict
odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.odedta read the news today, oh boy.
 
Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
Post the solution
odedta is offline   Reply With Quote
Reply

Tags
epub 3, epubcheck, validation errors

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
ePub validation error help "attribute border is not declared for element img bmacklin ePub 12 11-06-2015 11:00 AM
Validation Error:"The a element must not appear inside a elements" Lola25 ePub 10 11-12-2013 08:34 PM
W3C Validation says: Elements are undefined verydeepwater ePub 7 01-11-2013 05:09 AM
ePub validation error: 'element "span" not allowed here' nannygoats ePub 5 11-30-2011 08:47 AM
Validation: attribute 'start' is not declared for element 'ol' WS64 Sigil 4 10-06-2011 03:15 AM


All times are GMT -4. The time now is 04:02 AM.


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