简体   繁体   English

在没有打印机提示的情况下打印网页(HTML 5画布)

[英]Print web page (HTML 5 canvas) without printer prompt

I'm able to print HTML5 Canvas content. 我能够打印HTML5 Canvas内容。 But every time when I click print a window prompts to select printer and settings. 但是每次我单击“打印”时,都会出现一个窗口,提示您选择打印机和设置。

How to make silent printing? 如何进行静音打印? I need the browser to print in default printer without prompt. 我需要浏览器在没有提示的情况下在默认打印机中打印。

I need the solution for IE 10 and later, Edge and Chrome. 我需要针对IE 10和更高版本(Edge和Chrome)的解决方案。

This won't work as granting the web page access to printing without a prompt would be a security problem. 这将不起作用,因为在没有提示的情况下授予网页访问打印权限将是一个安全问题。

There may however be an option (flag) for disabeling the printing dialog in your browser. 但是,可能有一个选项(标志)用于取消浏览器中的打印对话框。 But this would affect all websites viewed in this browser. 但这会影响在此浏览器中查看的所有网站。

From a web application you cannot access resources on local machine like file system or installed applications. 您无法从Web应用程序访问本地计算机上的资源,例如文件系统或已安装的应用程序。 If you need this capability in your web application, you need to develop some browser plugin which can do this job. 如果您在Web应用程序中需要此功能,则需要开发一些浏览器插件即可完成此工作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM