You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.
View groupJoin the community to find out what other Atlassian users are discussing, debating and creating.
Hello,
New to Confluence (using on-demand). Working with styling PDF output and I'd like to hide section numbers in the table of contents.
With regular output, the process numbers my sections like this:
1.1.0, 1.1.1, 1.1.2, 2.1.1, etc.
I'd like to remove these completely.
In the advanced PDF instructions, I saw this code. Thought it might turn of section numbering completely:
/* Turn off the default section numbering for this TOC item */ .toclvl0:before { content: " "; counter-reset: chapter 0; }
However, what this seems to do is start the section numbers with a 0, like this: 0.1.1, 0.1.2.
What can I do to hide section numbers, but keep page numbers in the PDF output for a TOC?
Thanks!
Just in case you are interested:
There is another answer to the same question at https://answers.atlassian.com/questions/44440/pdf-stylesheet-any-guides-out-there#75579
Hi,
This did it for me:
span.tocnum:before { content: target-counter(attr(href), page, decimal ); } div.toc { page-break-after: always; } div.toc a { text-decoration: none; color: black; } div.toclvl0:before { display: none; } div.toclvl0 { padding-left: 20px; counter-reset: section 0; /* Set section to 0 */ } div.toclvl1:before { display: none; } div.toclvl1 { padding-left: 40px; counter-reset: subsection 0; } div.toclvl2:before { display: none; } div.toclvl2 { padding-left: 60px; counter-reset: subsubsection 0; } div.toclvl3:before { display: none; } div.toclvl3 { padding-left: 80px; counter-reset: subsubsubsection 0; } div.toclvl4:before { display: none; } div.toclvl4 { padding-left: 100px; }
My CSS skills are not top touch, you probably could have just removed the div.toclv13:before elements and gotten the same result. Or, if you want to allow for backing this out. Comment out what you don't want and put in just the display: none; with a note.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi, thank you for the response. That code works for me. Really appreciate the help!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Community! We're thrilled to share that Team Calendars for Confluence is now a built-in feature for Confluence Data Center releases 7.11 and beyond. A long time favorite, Team Cale...
Connect with like-minded Atlassian users at free events near you!
Find an eventConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.
Host an eventYou're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.