CSS-based PDF on wrong page header
Post here questions and problems related to editing and publishing DITA content.
-
- Posts: 6
- Joined: Fri Sep 06, 2019 10:58 am
CSS-based PDF on wrong page header
I’d like to display the page number at the bottom of the page instead top,
then I use the @page attributes in my CSS file, and specify:
@page {
@bottom-center {
content: counter(page);
font-family: "Arial","Microsoft YaHei", sans-serif; }
}
The page number is displayed on the bottom correctly.
But the header is still displayed and with wrong content, I don't even pecify it.
And another question: can I display the section title in the TOC when publishing in PDF?
then I use the @page attributes in my CSS file, and specify:
@page {
@bottom-center {
content: counter(page);
font-family: "Arial","Microsoft YaHei", sans-serif; }
}
The page number is displayed on the bottom correctly.
But the header is still displayed and with wrong content, I don't even pecify it.
image.png
how to remove the hader?And another question: can I display the section title in the TOC when publishing in PDF?
You do not have the required permissions to view the files attached to this post.
-
- Posts: 846
- Joined: Mon Dec 05, 2011 6:04 pm
Re: CSS-based PDF on wrong page header
Hi,
The default content of the page headers are defined through the default .css files that oXygen comes with. More specific, according to the "Default Page Definitions" section from the "DITA-OT CSS Publishing to PDF Plugin" User-Guide, the pages/headers are defined in the p-pages-and-headers.css file.
You could therefore override the rules from the default CSS. It is not recommended to modify the default CSS files, but use a customization CSS of your own instead, containing the overriding rules and passing the customization .css file to the transformation through the "args.css" parameter.
This way, you could hide the header content for specific pages (default pages / TOC pages, etc.), by setting the content: none; property on the appropriate selector that matches them.
Regards,
Costin
The default content of the page headers are defined through the default .css files that oXygen comes with. More specific, according to the "Default Page Definitions" section from the "DITA-OT CSS Publishing to PDF Plugin" User-Guide, the pages/headers are defined in the p-pages-and-headers.css file.
You could therefore override the rules from the default CSS. It is not recommended to modify the default CSS files, but use a customization CSS of your own instead, containing the overriding rules and passing the customization .css file to the transformation through the "args.css" parameter.
This way, you could hide the header content for specific pages (default pages / TOC pages, etc.), by setting the content: none; property on the appropriate selector that matches them.
Regards,
Costin
Costin Sandoi
oXygen XML Editor and Author Support
oXygen XML Editor and Author Support
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)
- ↳ 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