Firefox打印额外的空白页面 [英] Firefox prints extra blank page

查看:162
本文介绍了Firefox打印额外的空白页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个在Chrome,Safari和IE上正确打印的网页,但是在Firefox上有以下问题:

只打印第一页的页眉。其余的是空白的。
实际内容仅在第2页显示。



使用Google搜索一下,我发现float:left风格正在导致它。
如果我删除了float:left,它的打印效果不错,但它看起来并不像预期的那样,因为它需要在打印和屏幕上显示两列。

b
$ b

有没有解决这个问题的办法?

谢谢。

解决方案

尝试使用打印样式表:

< link rel =stylesheethref =print .csstype =text / cssmedia =print/>



在这个样式表中, float:left 用于打印,并且不会影响浏览器的布局。

Al


I have a web page that prints correctly on Chrome, Safari and IE, but has the followign problem on Firefox:

It prints just the header on the first page. The rest of it is blank. The actual content is shown only on page 2.

Googling a bit about it i found that the "float: left" style is causing it. If i remove the "float: left" it prints ok, but it does not look as it is supposed to as it needs to display 2 columns beside each other in print as well as on screen.

Is there a solution to this problem?

Thanks.

解决方案

Try using a print style sheet:

<link rel="stylesheet" href="print.css" type="text/css" media="print" />

In this style sheet you will be able to remove the float:left for print and not have it effect the layout in the browser.

Al

这篇关于Firefox打印额外的空白页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆