can't add content in the < fo:block break-before="page"> for DITA OT PDF plugin

Here should go questions about transforming XML with XSLT and FOP.
lisazeng
Posts: 29

can't add content in the < fo:block break-before="page"> for DITA OT PDF plugin

Thu Jul 13, 2017 12:55 pm

Hi all,

I use the DITA OT 2.5.

in the DITA OT PDF plugin, I want to add a new company disclaimer page after the cover page.
in the front-matter.xsl
<xsl:template name="createFrontCoverContents">
.....
<!--for the seconde page-->
<fo:block break-before="page">
</fo:block>


This works and I have new blank page after the cover page.
however, when I want to add some contents in the second page like this

<!--for the seconde page-->
<fo:block break-before="page">

<fo:block margin-top="10pt">
<fo:block text-align="right">
Disclaimer
</fo:block>
</fo:block>

</fo:block>
Then I got the error from oxygen,
Severity: error
Description: [fop] [ERROR] Anttask - Error rendering fo file: D:\test\temp\oxy-ug-pdf\oxygen_dita_temp\topic.fo <org.apache.fop.apps.FOPException


How can I solve this error as a novice.

Thanks!
Radu
Posts: 5100

Re: can't add content in the < fo:block break-before="page"> for DITA OT PDF plugin

Thu Jul 13, 2017 4:50 pm

Hi,

It looks like your XSL-FO file is invalid.
After the publishing fails there is a "DITA OT" console view at the bottom of Oxygen showing more details about the failure, including probably the line in the XSL-FO where the problem was found. You can open the XSL-FO file in Oxygen and maybe see what's wrong with it.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
lisazeng
Posts: 29

Re: can't add content in the < fo:block break-before="page"> for DITA OT PDF plugin

Fri Jul 14, 2017 9:01 am

Hi Radu,

I fixed all errors. and it seems that I can't use more parameters in <fo:block break-before="page" >.

if I use more parameters in this block, there is error shows however when I go to the specific fo file, there is green block on the right side of code. no specific error there.

why I can't have more parameters for this block <fo:block break-before="page" > and its inner block with front can't shown in the new blank page.

Thanks!
Radu
Posts: 5100

Re: can't add content in the < fo:block break-before="page"> for DITA OT PDF plugin

Fri Jul 14, 2017 9:27 am

Hi,

In order to help further I would need to know how the XSL:FO block looked initially when the error was reported, what the reported error message looked like (the last part in the DITA OT console view after the publishing failed).

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
lisazeng
Posts: 29

Re: can't add content in the < fo:block break-before="page"> for DITA OT PDF plugin

Fri Jul 14, 2017 12:31 pm

Hi Radu,

Good news is that I can pass the running now.
I just make multi parameter in multi lines and didn't combine them into the same line. so the pdf is shown now.


However, as for the fo:block code below, a new page is created but no content is shown even though there is a block contains message "The information in this document applies solely to the hardware/software product (“Product”) specified herein, and only as specified herein."


<fo:block break-before="page"
front-size= "8pt"
color="#68717A"
text-align="left"
margin-bottom="10mm"
margin-left="10mm">
<fo:block line-height="130%">
The information in this document applies solely to the hardware/software product (“Product”) specified herein, and only as specified herein.
</fo:block>
</fo:block>

do you know how to track it?
Radu
Posts: 5100

Re: can't add content in the < fo:block break-before="page"> for DITA OT PDF plugin

Fri Jul 14, 2017 1:59 pm

Hi,

There seems to be nothing wrong with your fo:block but probably it's the context in which it resides in the XSL-FO.
Without having an entire XSL-FO to look at it's hard to say what's wrong.
There is a public users list where you may ask XSL-FO questions:

https://www.mulberrytech.com/xsl/xsl-list/

Ideally you can create a trimmed-down XSL-FO file and ask there.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
lisazeng
Posts: 29

Re: can't add content in the < fo:block break-before="page"> for DITA OT PDF plugin

Tue Jul 18, 2017 7:36 am

Hi Radu,

Thanks very much! I am checking it and hope it works.

br,
Lisa

Return to “XSLT and FOP”

Who is online

Users browsing this forum: No registered users and 1 guest