PDF Page Numbers Restart at One in Each Chapter
Post here questions and problems related to editing and publishing DITA content.
			- 
				patjporter
 - Posts: 53
 - Joined: Sat May 22, 2021 6:04 pm
 
PDF Page Numbers Restart at One in Each Chapter
Post by patjporter »
Hello,
Sorry for another question!
My page numbers are starting over at 1 in each chapter. I am trying to figure out where in the css this is controlled. I am thinking it may be caused by this additional css I added that I got via a forum on Stackoverflow, where I was trying to start each level 2 heading on a new page, but yet keep the first level 2 heading together with the 1st level (chapter heading) as shown below:
1st instance:
Any ideas on how to keep my page numbers from restarting at 1 in each chapter?
Thanks!
Pat
			
			
						Sorry for another question!
My page numbers are starting over at 1 in each chapter. I am trying to figure out where in the css this is controlled. I am thinking it may be caused by this additional css I added that I got via a forum on Stackoverflow, where I was trying to start each level 2 heading on a new page, but yet keep the first level 2 heading together with the 1st level (chapter heading) as shown below:
1st instance:
image.png
2nd instance:image.png
Here is something very weird though...I do not get the page breaking in the first chapter...only in Chapter 2 and subsequent:image.png
Here is the css that was provided to get the page breaking at the level 2 heading for all but the first instance (I put it in a custom.css file):Code: Select all
/* BREAK MAIN TOPICS TO NEW PAGE */
article h2 {
page-break-before: always;
}
article:first-of-type h2 {
page-break-before: avoid;
}Thanks!
Pat
You do not have the required permissions to view the files attached to this post.
			
									
						- 
				chrispitude
 - Posts: 922
 - Joined: Thu May 02, 2019 2:32 pm
 
Re: PDF Page Numbers Restart at One in Each Chapter
Post by chrispitude »
Here is information on controlling the numbering:
https://www.oxygenxml.com/doc/versions/ ... intro.html
You will probably want to set the args.css.param.numbering parameter to deep-chapter-scope-no-page-reset.
(By the way, there is a dedicated "PDF Chemistry" section of this forum that is specific to the PDF-CSS-HTML5 transformation here.)
			
			
									
									
						https://www.oxygenxml.com/doc/versions/ ... intro.html
You will probably want to set the args.css.param.numbering parameter to deep-chapter-scope-no-page-reset.
(By the way, there is a dedicated "PDF Chemistry" section of this forum that is specific to the PDF-CSS-HTML5 transformation here.)
- 
				patjporter
 - Posts: 53
 - Joined: Sat May 22, 2021 6:04 pm
 
Re: PDF Page Numbers Restart at One in Each Chapter
Post by patjporter »
Thank you very much!
I will move to that forum if I have further questions. You tip corrected the issue and now my document is publishing exactly as I would like it.
Pat
			
			
									
									
						I will move to that forum if I have further questions. You tip corrected the issue and now my document is publishing exactly as I would like it.
Pat
Return to “DITA (Editing and Publishing DITA Content)”
			
				Jump to
				
			
		
			
			
	
	- Oxygen XML Editor/Author/Developer
 - ↳ Feature Request
 - ↳ Common Problems
 - ↳ DITA (Editing and Publishing DITA Content)
 - ↳ Artificial Intelligence (AI Positron Assistant add-on)
 - ↳ SDK-API, Frameworks - Document Types
 - ↳ DocBook
 - ↳ TEI
 - ↳ XHTML
 - ↳ Other Issues
 - Oxygen XML Web Author
 - ↳ Feature Request
 - ↳ Common Problems
 - Oxygen Content Fusion
 - ↳ Feature Request
 - ↳ Common Problems
 - Oxygen JSON Editor
 - ↳ Feature Request
 - ↳ Common Problems
 - Oxygen PDF Chemistry
 - ↳ Feature Request
 - ↳ Common Problems
 - Oxygen Feedback
 - ↳ Feature Request
 - ↳ Common Problems
 - Oxygen XML WebHelp
 - ↳ Feature Request
 - ↳ Common Problems
 - XML
 - ↳ General XML Questions
 - ↳ XSLT and FOP
 - ↳ XML Schemas
 - ↳ XQuery
 - NVDL
 - ↳ General NVDL Issues
 - ↳ oNVDL Related Issues
 - XML Services Market
 - ↳ Offer a Service