Discussions
Help with Paging Html - PDF
about 2 months ago by Dale Fraser
I have a html template that generates a PDF
The page has a fixed header and footer and the page content needs to have a top and bottom margin to avoid overlap of the header / footer
However Ive tried many combos, but using
@page {
margin-top: 50px;
}
I get the right paging but the fixed header is also moved down 50px, I need it at the top
Most recent version of header which doesnt work is
header {
margin-top: 0px;
position: fixed;
top: 0;
left: 0;
right: 0;
height: 50px;
border-image: linear-gradient(to left, @(Model.BrandColor) 34%, #D9D9D6 34%);
border-image-slice: 5;
border-top: 28px solid transparent;
width: 100%;
box-sizing: border-box;
padding: 10px 10px;
}