[英]css print preview page is cut
As you can see in this Image , The title of the next table is being cut when the first table is having more records, sometimes the table before page break is long sometimes its short. 如您在该图像中所看到的,当第一个表具有更多记录时,下一个表的标题将被剪切,分页符之前的表有时很长,有时又很短。
How can i make a dynamic margin adjustment at the bottom? 如何在底部进行动态边距调整? To avoid those unwanted cutoffs? 为了避免不必要的截止?
@page {
margin-top: 13mm;
margin-left: 1px;
margin-right: 1px;
size: short;
}
@media print {
html, body {
width: 250mm;
height: 297mm;
}
/* ... the rest of the rules ... */
}
according to your images, I guess you can try page-break-before
or page-break-after
根据您的图片,我想您可以尝试page-break-before
或page-break-after
@media print {
h1 {
page-break-before: auto | always | avoid | left | right | inherit;
page-break-after: auto | always | avoid | left | right | inherit;
}
}
And two articles might explain these two CSS properties, click here and click here 有两篇文章可能会解释这两个CSS属性, 请单击此处 , 然后单击此处
if you can provide some code or example on fiddler will be awesome for others to help you 如果您可以在Fiddler上提供一些代码或示例,那么其他人可以帮助您
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.