如何从网页生成打印输出 [英] How to generate printout from webpage

查看:146
本文介绍了如何从网页生成打印输出的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在网页上制作一个考试表格,当用户在提供相关信息后保存表格时,表格会转换成可打印的形式。请告诉我这是怎么可能的..

解决方案

可打印表单不代表同一页面,只有不同的样式。你真正需要知道的是CSS。它曾经是网站的一个非常常见的设计元素,但它不是最好的方式:CSS @media功能。您可以提供相同的内容,但使用不同的CSS规则进行隐藏会根据媒体重新排列某些元素。请参阅:

http://www.w3schools.com/css/css_mediatypes.asp [ ^ ],

http://www.w3.org/TR/CSS2/media.html [ ^ ],

https://developer.mozilla.org/en-US/docs/CSS/@media [< a href =https://developer.mozilla.org/en-US/docs/CSS/@mediatarget =_ blanktitle =New Window> ^ ]。



祝你好运,

-SA


i m making a examination form on a webpage i want to do that when user save the form after giving related information the form convert into printable form.. plz tell me how it is possible..

解决方案

"Printable form" means nothing that the same page, only with different styles. All you really need to know is CSS. It used to be a very usual design element of the Web sites, but it is not the best way: CSS @media feature. You can provide the same content, but use different CSS rules to hide are re-arrange some elements depending on the media. Please see:
http://www.w3schools.com/css/css_mediatypes.asp[^],
http://www.w3.org/TR/CSS2/media.html[^],
https://developer.mozilla.org/en-US/docs/CSS/@media[^].

Good luck,
—SA


这篇关于如何从网页生成打印输出的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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