如何将css应用于打印预览页面 [英] how to applying css for print preview page
本文介绍了如何将css应用于打印预览页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要为所有主要浏览器打印带有桌面和背景颜色边框的页面,但是我无法获得那个。
我尝试了很多步骤,我搜索过外部样式表和内部样式表
Hi,
I need to print a page with some borders for table and background colours for div for all major browsers , but i''m unable to get that one.
I''ve tried many steps that i searched like external stylesheet and internal stylesheet
<link href="print_style.css" rel="Stylesheet" type="text/css" media="print" />
<style type="text\css" media="print">
</style>
但这些都没有帮助我,我也不需要任何手动浏览器设置。
在此先感谢。
but none of this helps me and i don''t need any manual browser settings.
Thanks in advance.
推荐答案
您可以使用媒体类型。请参阅:
http://www.w3schools.com/css/css_mediatypes.asp [ ^ ],
http://www.w3.org/TR/CSS2/media.html [ ^ ]。
-SA
You can use media types. Please see:
http://www.w3schools.com/css/css_mediatypes.asp[^],
http://www.w3.org/TR/CSS2/media.html[^].
—SA
这篇关于如何将css应用于打印预览页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文