Hi everyone,
I'm trying to add page numbers to the table of contents (TOC) in a Confluence PDF export:
div.toc a::after { content: leader('.') target-counter(attr(href), page); }
However, I’ve noticed that in PDF Export v2, these CSS properties (target-counter()
and leader()
) are no longer supported. This means that automatic page numbering in the TOC no longer works in the exported PDF.
My question:
Is there another way to add page numbers to the TOC in Confluence's PDF export system?
@Ray Mackaaij Welcome to the Atlassian Community.
I haven't had a need to generate a PDF from Confluence for a while, but I just tried it, and my TOC has page numbers.
My settings:
To me, that indicates that something in the PDF Export settings is causing the page numbers to not appear in the output.
Hi Barbara,
Thanks for your reply! I didn’t realize there’s an export option within the space. I had been using the one on the page itself, accessed through the three dots.
Now I can see the table of contents with page numbers, which is really useful. However, I’m having trouble customizing the layout through CSS in the PDF stylesheet to fit my needs.
Have you worked with this before? Any advice would be greatly appreciated!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Ray Mackaaij No, I don't really make PDFs from Confluence. We decided to use the Scroll Viewport app to publish our content to a website accessible by our readers. I can publish an update of the documentation following our sprint/release schedule.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.