Have you tried checking the “Validate content before download” in the plugin settings? The plugin has a checkbox to validate the content before generating the book https://share.cleanshot.com/YUHwpL. It may be related.
If no errors are found, try to refine your generation by choosing fewers posts until you find which post is responsible for corrupting the file.
Yes, Validate Content is checked, but, if it is giving any validation errors, I don’t see them anywhere.
I did chooses fewer posts, and have found that there are a handful that are causing the error. I am at a loss to know why though. All the posts in the series are formatted identically. I edited one of them and updated it, but it made no difference.
Could you share with me the URL of both examples? (One of a post which is giving an error and one of a posts which is ok)
If you prefer to do it privately, you can write me at ferran@mpl-publisher.com)
Thanks. Let me do a few checks and I will get back to you with my findings.
Hi @edjarrett
I think I’ve found a reason. The error is due using & in your text. If you can confirm it, the pages that does not work should have a & and the others don’t.
I will release a new version to address this issue in the coming days. Until then, if you have the chance to edit the PHP plugin’s code, you can add this line to fix the issue:
https://github.com/ferranfg/mpl-publisher/blob/master/libs/WordPublisher.php#L44
Thanks. Removing the & from the one post did fix it. I will all that line of code in a little while. Thanks for your help on this.
I have added that line of code, and it seems to work well now. Thanks again.
I did notice that the headings in my post become normal text in the Word document. Is that how it is supposed to work? It is not a big deal since I have to edit the file anyway to remove parts of the posts that are appropriate for a single post but not when they are combined into a single document.
Hi @edjarrett
Glad it’s working. Thanks to you for your finding and patience.
Regarding the heading, I’ve seen that new versions of the library the plugin uses internally to generate the Word document support appropriate headings, so I’m preparing a new plugin release to address this issue.
Version 2.7 should support this feature. Most probably at the end of this week or the following.