How do you display dynamically created Confluence tabs in the exported PDF file?

I created two user macros: one for the 'tabs container', and one for creating tabs. You insert as many 'tab' user macros inside the 'tab container' user macro. I'm using the Confluence tabs shown on this page: https://docs.atlassian.com/aui/latest/docs/tabs.html

 

The tabs render correctly in HTML, but when I export to a PDF, nothing gets displayed but the outline of the 'tabs container'. The 'tabs container' user macro uses JS to create an unordered list of tab anchors from the content added to the inserted 'tab' user macros. Again, this works great for HTML pages, but not for the exported PDF.

Also, is there a way to access the content of the inserted user macros through the $content or other Confluence objects of the parent 'tabs container'? If that was possible, I could theoretically create static HTML and possibly correct the problem. I'm assuming this issue is because of the rendering of the $body in the 'tab' user macro because when I just use the HTML macro to enter the tabs as shown in the page above, it renders in the HTML page and also gets displayed in the exported PDF, although the presentation of the PDF is not great. Thanks in advance for any help. 

1 answer

Not sure if this is still relevant for you, but you might want to try the Scroll PDF Exporter which supports more macros and has more styling options than the Confluence out of the box one.

See also this entry which might be your use case.

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Kesha Thillainayagam
Posted Apr 13, 2018 in Confluence

We want to hear how your non-technical teams are using Confluence!

Hi Community! Kesha (kay-sha) from the Confluence marketing team here! Can you share stories with us on how your non-technical (think Marketing, Sales, HR, legal, etc.) teams are using Confluen...

2,775 views 26 10
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you