Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,293,780
Community Members
 
Community Events
165
Community Groups

PDF page numbering

Edited

Hi all,

I'd like to recap how you can add page numbers on PDF exports in Confluence. This is heavily based on the post below:

https://community.atlassian.com/t5/Confluence-questions/Updated-HOW-TO-Get-Page-Numbers-On-PDF-Exports/qaq-p/887863 

The code snippet below seems to be working fine with both Confluence Server and Cloud (and I imagine Data Center). It also moves the page name to the header of each page.

.pagetitle h1 {
display: block;
position: running(pagenametop);
font-family: ConfluenceInstalledFont, Helvetica, Arial, sans-serif;
font-size: 8pt;
}

@page
{ margin: 0.7in;

@Top-left
{
content:element(pagenametop);
}

@bottom-left
{
content: "NOT CONTROLLED WHEN PRINTED OR IN PDF"; /* Content to appear bottom left side of page */
font-family: ConfluenceInstalledFont, Helvetica, Arial, sans-serif;
font-size: 8pt;
padding-bottom: 3em;
}
@bottom-right
{
content: "Page " counter(page) " of " counter(pages); /* Page and page NUMBER counter to appear bottom right side of page */
font-family: ConfluenceInstalledFont, Helvetica, Arial, sans-serif;
font-size: 8pt;
padding-bottom: 3em;
}

}

/* Body font pdf export */
body,p,li,td,table,tr,.bodytext,.stepfield
{
font-size: 10pt;
line-height: 1.25 !important;
}

 

0 comments

Comment

Log in or Sign up to comment
TAGS
Community showcase
Published in Confluence

Confluence: Where work and wellness meet

Feeling overwhelmed by the demands of work and life? With a 25% increase in the prevalence of anxiety and depression worldwide during the pandemic, for most of us, it’s a resounding yes . 🙋‍♀️ ...

765 views 5 21
Read article

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you