【问题标题】:printing the html with custom spacing between printer margin and the content在打印机边距和内容之间使用自定义间距打印 html
【发布时间】:2019-11-15 03:01:39
【问题描述】:

我正在打印动态创建的 html iframe。当我调用 window.frames['fr-print'].print();它打印html文档的方法但是在打印文档时我想在打印机的边距和我的html内容之间留出空间因为我想在每个页面的底部都有版权消息所以我制作了一个div并通过将 div 位置设置为 position:fixed;底部:0;但我在每一页的内容都与版权信息重叠。有什么办法可以在打印机边距和每页的 html 内容之间留出空间。

我为@page CSS 规则添加了底部边距,但它会影响打印机的边距设置。并且还尝试将整个动态控件添加到一个 div 中并为 div 添加边距底部,但它只在最后一页应用边距。

【问题讨论】:

    标签: javascript jquery html css media-queries


    【解决方案1】:

    当您单击“打印”按钮时,此文本会被删除。 $("#COPYRIGHT-ID").TEXT("");

    【讨论】:

      猜你喜欢
      • 2011-09-13
      • 1970-01-01
      • 1970-01-01
      • 2012-03-29
      • 1970-01-01
      • 2017-04-20
      • 2011-07-06
      • 2010-12-05
      相关资源
      最近更新 更多