error on rendering pdf in the cms
Hi,
I got this error when rendering a pdf using stock xslt pdf transformation in the cms. Here is the error.
=================== Nov 29, 2010 9:08 AM
An error occurred: An error occurred while rendering the PDF:
org.apache.fop.fo.ValidationException: null:43:53: Error(43/53):
fo:list-block is missing child elements. Required Content Model:
marker* (list-item)+
You may choose to retry the operation. If the problem persists, please contact a system administrator.
The error has been logged to the system console.
Home
I'm attaching a log file. It might have something to do about either multiple content in the data definition or images.
- cascade.log.zip 2.56 KB
Discussions are closed to public comments.
If you need help with Cascade CMS please
start a new discussion.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
1 Posted by Ross on 29 Nov, 2010 05:01 PM
That looks to me that the xhtml2fo2pdf format is encountering an HTML
<ul>
or<ol>
element that doesn't have any<li>
children. It unwittingly generates the<fo:list-block>
element from the unordered or ordered list element, but then no<fo:list-item>
elements get generated, causing the error.Let us know if you can't find any content with missing list items.
2 Posted by csaladores on 29 Nov, 2010 07:01 PM
Thanks Ross. There was a <ul> tag without <li>. Now I get this error:
==========================
Nov 29, 2010 1:57 PM
An error occurred: An error occurred while rendering the PDF: org.apache.fop.fo.ValidationException: null:59:32: Error(59/32): fo:inline is not a valid child element of fo:list-block.
You may choose to retry the operation. If the problem persists, please contact a system administrator.
The error has been logged to the system console.
Home
==========================
What does this mean?
3 Posted by Ross on 29 Nov, 2010 07:09 PM
Sounds like there is another list that has a (direct) child other than <li>.
HTML elements like <b>, <strong>, <i>, <em>, <code>, <big>, <small>, <span>,
etc. all generate <fo:inline> elements. They're allowed INSIDE of <li>
elements but not directly under <ul> or <ol>.
On Mon, Nov 29, 2010 at 2:01 PM, csaladores <
[email blocked]<tender%[email blocked]>
> wrote:
4 Posted by csaladores on 29 Nov, 2010 07:35 PM
Yup, i removed any tag other than <li> in the <ul> tag. When I removed that, it gave me this error:
=======================
Nov 29, 2010 2:34 PM
An error occurred: An error occurred while rendering the PDF: Gap in the kids list!
You may choose to retry the operation. If the problem persists, please contact a system administrator.
The error has been logged to the system console.
Home
=======================
I'm not sure what this means.
5 Posted by Ross on 29 Nov, 2010 07:48 PM
Basically what
Gap in the kids list
means is that one of the pages of the PDF failed to render properly. This can be caused by any number of issues in the HTML to PDF conversion; the error message is frustratingly vague.I'd recommend that you first check the
cascade.log
file in the server'slog
directory to see if there are any other PDF-related errors. If you're only encountering this on one Page asset, then the problem is likely with the WYSIWYG content of that page. If it is occurring on all pages, we may need to take a different tack.If you're seeing the problem just on one (or a few) pages, paste the WYSIWYG content of the page into a very basic HTML template like the following, and validate that content at http://validator.w3.org
6 Posted by csaladores on 29 Nov, 2010 08:48 PM
Great, thanks Ross for the tip. It's just one page asset. It may have to do with the WYSIWYG content. I'll use the validator to validate content for the pdf. Thanks again.
Ross closed this discussion on 04 Mar, 2011 06:16 PM.