Forum How do I...?

Total Page Count of a Section

twantzen
With the start of each section with a specific class inside one HTML file we do a
counter-reset: page 1;

In the footer we’d like to throw out something like
content: 'Page ' counter(page) '/' counter(pages);

counter(page) ist the actual page number – that’s fine –, but counter(pages) is always the total page count of the PDF.
Is it possible to get the total page count per section and how do I get this?

Thanks
Tobias
mn4367
You can do the same with the pages counter:

counter-reset: pages;


or in one statement:

counter-reset: page 1 pages 1;

twantzen
This is great! Thank you very much!!