ePub navMap element error - itunes

I have been trying to convert my docx file to epub but having a problem in the validation of epub in the itunes producer and also on online epub validations,
the error is
"A.epub: OPS/toc.ncx(2): element "navMap" not allowed here; expected the element end-tag or element "navList" or "pageList"
i dont have any idea to solve this problem, please help!

Well, you need to show us the ncx file, or at least more of it. First boil it down to the smallest case that produces the error. By the way, in doing that, you'll find the problem yourself. That's called "debugging".

Related

PDF Link Annotation unable to tag properly?

I am trying to tag link annotation using PDFBOX, Its tagging fine(refrence code). But after tagging if I open tag properties in adobe its empty.
Next after this annotation tagging the images also throwing some error (even though alt-text is there) like
Here the error file which is the first image right side one, Please let me know what I did wrong.

Yii2: Setasign fpdi

I am creating an application and used fpdi for the printable documents. But when I ran the code, it returned an error: setasign\Fpdi\PdfParser\PdfParserException . What are the possible causes of this error?
As you can see from the code, parser tries to find PDF keyword in the file header. But does not find.
PDF file is corrupted or empty.
header("Content-type:application/pdf");
Add this line to your code.

Selenium 2.0 - File Upload not working

I am unable to upload a file using selenium. I employ the below code:
Browser.FindElement(By.XPath(XPath)).SendKeys(path);
However, all that happens is that the file browse form comes up. The file does not get selected.
Does anyone know what I need to do to get this working, or a workaround? Many Thanks.
Refer to(saucelabs.com/resources/selenium-file-upload)
WebElement upload = driver.findElement(By.id("myfile"));
upload.sendKeys("/Users/sso/the/local/path/to/darkbulb.jpg");
driver.findElement(By.id("submit")).click();
driver.findElement(By.tagName("img"));
Also make sure you have given the path correctly. For example if the file is in d:\abc\pqr.txt, then path needs to be given as
"d:\\abc\\pqr.txt"
Mark this as an answer if this answers your question.
If not, please post your query!
Regards,
Sakshi

Mysterious FireBug Error repeats with ExtJS

When debugging ExtJS 4 (tried both versions 4.1.0 and 4.1.1), FireBug repeatedly shows the following error: An invalid or illegal string was specified
http://docs.sencha.com/ext-js/4-1/extjs/ext-all.js
Line 18. It does not break on the error, though that option is specified. Additionally, neither my code or ext-debug.js and it's loader seem to actually call ext-all.js.
This error gets logged to Firebug's console about once per minute, which is annoying. What bothers me is that I cannot get the error to go away. Is this a FireBug bug? An ExtJS bug? Aliens? How can I debug the debugger?
I had the same problem before and I've solved it by removing a special character at the end of my JS file! (app.js I think)
It was weird, but the problem came from hidden special characters like: Zero-width non-joiner or Right-to-left mark.
Open another JS file but do not copy/paste your code there. Just write it again and check whether the problem exists or not.
And don't forget to check your data if you have some. As this article explains about the problem: http://www.ashorlivs.fr/javascript-jquery/article/an-invalid-or-illegal-string-was
For general debugging see this link http://www.sencha.com/learn/debugging-ext-js-applications/
You can also use ext-all-dev.js while in development mode.
There is another excellent tool on top of firebug, at this link http://www.illuminations-for-developers.com/
PS: I still didn't figured out how to post a comment. I guess it comes when I have more points/reputation. Hence adding it as an answer. thanks.

zend_pdf can't read existing pdf

I'm using Zend_Pdf to generate PDF files, based on existing PDF templates. The problem is, I can't read any of the templates - I get a "File is not a PDF." error because the first 4 characters in the file are "%???" instead of "%PDF" (I used "head" to check this).
Is this a character encoding problem? I believe the templates are in ISO-8859-1, must I set something in Zend_Pdf_Parser to handle this?
Thanks
to answer my own question, I moved to Perl PDF::Extract and it's working.