Formulas structure is changing when exported to PDF.

Issue #96 resolved
Ravi Teja kommana created an issue

Hi

We Migrated some spaces from one instance of confluence to our confluence server. The source instance is using Latex math add-on and the destination our instance is using mathjax for formulas. So during the migration, we converted latex math formulas to mathjax formulas using the below process.

We are finding the following expression in the contents of each page using regular expressions -

<ac:structured-macro ac:name=""mathinline"".+?><ac:parameter ac:name=""body"">.+?</ac:parameter>

Replace the contents of the matched expression with the following -

"<ac:parameter ac:name="body">" is replaced with "<ac:plain-text-body><![CDATA["

"</ac:parameter>" is replaced with "]]></ac:plain-text-body>"

After the replacement, the macro works and the latex conversions are displayed properly on the page. But when we export the page to PDF formulas structure is changing. Could you please help us to fix it.

Thanks,
Ravi Teja

Comments (1)

  1. Scott Selberg

    Hi, MathJax is an open source javascript library for which I wrote macros to load. Being javascript, the rendering of the equation happens in your browser as the page loads reather than on the confluence server. When conflunence exports a page to pdf, it renders everything on the server before uploading so the javascript functionality is not executed. So with MathJax you will not see the rendred equations in the pdf. If this is important to you, you should stay with the latex add on.

  2. Log in to comment