我想在 Firefox 当前页面 html 中替换字符串(“123”与“111”)。
解释:
我正在打开 Firefox,然后我正在导航到:
www.site.com/print.php?string=123
我正在等到文件完全加载
页面html:
<html>
<body>
123
</body>
</html>
我将字符串“123”替换为“111”。
代码应如下所示:
openff("http://www.site.com/print.php?string=123") 'open url
again:
For Each p As Process In Process.GetProcessesByName("firefox") 'wait until page is fully loaded
If p.MainWindowTitle = "123 page title" Then
Exit For
Else
Application.DoEvents()
GoTo again
End If
Next
replaceInFFcurrentDocHtml("123", "111") 'Replace the string!!!
该功能replaceInFFcurrentDocHtml()
实际上并不存在。
有一个函数可以replace
在firefox当前页面html中字符串吗?
或者get
当前 html 来自的函数firefox
?
(我试图通过 spy++ 使用句柄和窗口获取 html,但这种方式不起作用)