如何从 Firefox 外部访问 Firefox 的 DOM(或 HTML 内容) [英] How to access Firefox's DOM (or HTML content) from outside firefox

查看:37
本文介绍了如何从 Firefox 外部访问 Firefox 的 DOM(或 HTML 内容)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个问题:

我的程序将搜索用户打开的 FireFox 窗口.当用户打开 Firefox 并进入任何站点时,我想在该页面的 HTML 内容中搜索关键字.

My program will search FireFox windows opened by user. When a user open Firefox and enter any site, I want to search for a keyword in that page's HTML content.

如何使用我的 C++ 程序从 Firefox 外部访问 Firefox 的 Active Tab 的 DOM(或 HTML 内容).

How can I access Firefox's Active Tab's DOM (or HTML content) from outside firefox using my C++ program.

有可能吗?如果是这样,你能给我一些想法或链接吗?

Is it possible? If so, can you give me some idea or links?

如果不可能,我如何在不安装/设置任何东西的情况下将文本复制到 Firefox 中的剪贴板?

If it is not possible, how can I copy text to clipboard within Firefox without installing / setting up anything?

最好的问候,努里·阿克曼

Best regards, Nuri Akman

推荐答案

没有内置方法可以从外部程序访问 Firefox 内部网页的 DOM.您可以编写一个实现某种 IPC(使用套接字或其他方式)的扩展并与之通信,但不是 Firefox 内置的.

There is no built-in way to access the DOM of a web page inside Firefox from an external program. You can write an extension that implements some sort of IPC (using sockets or whatever) and communicate with that, but not built-in to Firefox.

这篇关于如何从 Firefox 外部访问 Firefox 的 DOM(或 HTML 内容)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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