《沉默》在 Web 应用程序中打印 [英] "Silent" Printing in a Web Application

查看:22
本文介绍了《沉默》在 Web 应用程序中打印的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个需要静默打印的 Web 应用程序——无需用户参与.实现这一目标的最佳方法是什么?它不喜欢严格使用 Javascript、Flash 和/或 AIR 来完成.我见过的最接近的是 Java 小程序.

I'm working on a web application that needs to prints silently -- that is without user involvement. What's the best way to accomplish this? It doesn't like it can be done with strictly with Javascript, nor Flash and/or AIR. The closest I've seen involves a Java applet.

我能理解为什么任何网站都能够做到这一点是个坏主意.这个特定的实例是针对内部应用程序的,如果用户需要将 URL 添加到受信任的站点列表、安装插件等,这是完全可以接受的.

I can understand why it would a Bad Idea for just any website to be able to do this. This specific instance is for an internal application, and it's perfectly acceptable if the user needs to add the URL to a trusted site list, install an addon, etc.

推荐答案

以下是您需要执行的操作,才能让 Firefox 立即打印而不显示打印首选项对话框.

Here’s what you need to do to enable Firefox immediately print without showing the print preferences dialog box.

  1. 在 Firefox 的位置栏中输入 about:config 并按 Enter.

  1. Type about:config at Firefox’s location bar and hit Enter.

右键单击页面上的任意位置并选择新建">布尔值"

Right click at anywhere on the page and select New > Boolean

输入首选项名称为 print.always_print_silent 并单击确定.

Enter the preference name as print.always_print_silent and click OK.

<小时>

我在某处找到了它并帮助了我


I found that somewhere and it helped me

这篇关于《沉默》在 Web 应用程序中打印的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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