dongmou9260 2013-05-17 05:51
浏览 81
已采纳

通过网络打印800毫米(收据)表(PHP)

How can I print a receipt sheet "800 mm width" via my web application?

I tried many times but can't get a cross-browser support for this feature,
for example, Chrome shrinks the page and print a "blurred" text on the receipt, but Firefox just print the right side only of the page "magnified, as if it was an A4 page".

also, after some searching there's no specific solid code to use.

so, what's the best practice to follow in order to enable receipt-printing on our web applications?

Thanks!

Can't post the receipt picture because I'm new here :)

  • 写回答

1条回答 默认 最新

  • dsfsdfsdfsdf6455 2013-05-17 06:01
    关注

    I solved this issue with two actions: i) Table column set to 350 width. ii) Use a css just for printed output. For example, one css file to web display and a second css file that must be invoked just by scripts whose action is to print something. Also when calling the css stylesheet use media="print" in the same <link href=....>

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
编辑
预览

报告相同问题?

手机看
程序员都在用的中文IT技术交流社区

程序员都在用的中文IT技术交流社区

专业的中文 IT 技术社区,与千万技术人共成长

专业的中文 IT 技术社区,与千万技术人共成长

关注【CSDN】视频号,行业资讯、技术分享精彩不断,直播好礼送不停!

关注【CSDN】视频号,行业资讯、技术分享精彩不断,直播好礼送不停!

客服 返回
顶部