简体   繁体   English

如何访问 chrome 浏览器的打印对话框以使用 chrome 扩展进行 DOM 操作

[英]How to access print dialog of chrome browser to do DOM manipulation with chrome extension

Hello folk I just want to know is there a way for a chrome extension to access the print dialog created by the chrome browser using Ctrl + P command大家好,我只想知道 chrome 扩展是否可以使用 Ctrl + P 命令访问由 chrome 浏览器创建的打印对话框在此处输入图像描述

In javascript, you may call the following function:在 javascript 中,您可以调用以下 function:

window.print();

You can learn more about it here .您可以在此处了解更多信息。
This can be called in most browsers without special priveleges.这可以在没有special权限的大多数浏览器中调用。

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

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