简体   繁体   English

C#:带代理和JavaScript的无头浏览器

[英]C#: Headless Browser with Proxy and JavaScript

I am currently using SimpleBrowser.WebDriver , a headless browser, for a project. 我目前正在使用SimpleBrowser.WebDriver ,一个无头浏览器,用于项目。 The browser only needs to be able to run some basic javascript code on a page, I do not want to manipulate the site with jscript or something. 浏览器只需要能够在页面上运行一些基本的javascript代码,我不想用jscript或其他东西操纵网站。

Is there any way to set a proxy for it? 有没有办法为它设置代理? If not, can you recommend another solution for a headless browser with javascript and proxy support? 如果没有,你能推荐另一种带有javascript和代理支持的无头浏览器解决方案吗?

Thanks in advance 提前致谢

PhantomJS will help you here: http://phantomjs.org/ There is a webdriver for it: http://www.tomdupont.net/2013/08/phantomjs-headless-browser-for-net-webdriver.html PhantomJS将在这里帮助你: http ://phantomjs.org/它有一个webdriver: http//www.tomdupont.net/2013/08/phantomjs-headless-browser-for-net-webdriver.html

How to setup proxy: Add proxy to PhantomJSDriver (Selenium C#) 如何设置代理: 将代理添加到PhantomJSDriver(Selenium C#)

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

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