web页面打印
关键字: 页面打印,打印HTML打印属性
打印HTML文档总是会出现问题。在CSS2中,我们可以借助打印属性让打印web内容更容易一些。
|
属性 |
描述 |
值 |
W3C |
|
orphans |
Sets the minimum number of lines for a paragraph that must be left at the bottom of a page |
number |
2 |
|
marks |
Sets what sort of marks should be rendered outside the page box |
none crop cross |
|
|
page |
Sets a page type to use when displaying an element |
auto identifier |
2 |
|
page-break-after |
Sets the page-breaking behavior after an element |
|
2 |
|
page-break-before |
Sets the page-breaking behavior before an element |
|
2 |
|
page-break-inside |
Sets the page-breaking behavior inside an element |
|
2 |
|
size |
Sets the orientation and size of a page |
|
|
|
widows |
Sets the minimum number of lines for a paragraph that must be left at the top of a page |
number |
2 |
Media Types 设备类型
|
Media Type |
CSS Version |
Compatibility |
Description |
|
all |
CSS2 |
IE4+ |
用于所有设备类型 |
|
aural |
CSS2 |
NONE |
用于语音和音乐合成器 |
|
braille |
CSS2 |
NONE |
用于触觉反馈设备 |
|
embossed |
CSS2 |
NONE |
用于凸点字符(盲文)印刷设备 |
|
handheld |
CSS2 |
NONE |
用于小型或手提设备 |
|
print |
CSS2 |
IE4+ |
用于打印机 |
|
projection |
CSS2 |
NONE |
用于投影图像,如幻灯片 |
|
screen |
CSS2 |
IE4+ |
用于计算机显示器 |
|
tty |
CSS2 |
NONE |
用于使用固定间距字符格的设备。如电传打字机和终端 |
|
tv |
CSS2 |
NONE |
用于电视类设备 |
|
|
|
|
|
*注: 倘若是需要页面全部输出打印,则需要将代码
改为代码
然后
进IE->工具->Internet选项->高级->打印 选中打印背景颜色和图片,这样就ok啦!
发表评论
- 浏览: 43683 次
- 性别:

- 来自: 上海

- 详细资料
搜索本博客
我的相册
共 46 张
最近加入圈子
链接
最新评论
-
成功的用户体验必须遵循的 ...
是的,真正从用户需求和网站目标开始说起的话,有很多可以说~ 等后面有时间写点更加 ...
-- by tiger.passion -
成功的用户体验必须遵循的 ...
还可以说的更详细点阿!
-- by lxdhdgss -
SEO之网站结构优化
有没有 优化 比较好的 网站例子 共享下
-- by 风雪涟漪 -
SEO之网站结构优化
不错 。学习了。期待有更好的文章
-- by 风雪涟漪 -
Firefox 3 Beta 4已完成测 ...
迫不及待呀
-- by boy in the road






评论排行榜