从 Google Chrome 扩展程序启动外部应用程序? [英] Start an external application from a Google Chrome Extension?

查看:63
本文介绍了从 Google Chrome 扩展程序启动外部应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何从 Google Chrome 扩展程序启动外部应用程序?

所以基本上我有一个可执行文件,可以在您启动它时完成这项工作.我需要能够在没有窗口的情况下启动它(它是一个控制台应用程序)并在参数中将当前 URL 传递给它,

So basically I have an executable file which does the job when you launch it. I need to be able to start it without a window (it is a console application) and pass the current URL to it in an argument,

推荐答案

以前,您可以通过 NPAPI 执行此操作插件.

但是,Google 现在正在逐步为 Chrome 使用 NPAPI,因此首选方法是使用 本机消息传递 API.外部应用程序必须注册本地消息传递主机才能与您的应用程序交换消息.

However, Google is now phasing out NPAPI for Chrome, so the preferred way to do this is using the native messaging API. The external application would have to register a native messaging host in order to exchange messages with your application.

这篇关于从 Google Chrome 扩展程序启动外部应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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