Jomasdf
Power Member
- Jul 7, 2012
- 664
- 362
I want to connect via proxy.
It appears to be working fine, according to the console window my proxyType is set to "none" and the httpProxy to the ip of the proxy.
But I got suspicious to if it was acctually working so I had it connect to a random IP-checking website and take a screenshot. It showed my real IP.
I'm now completely clueless as to what might be wrong with it. Alternativly I would appreciate alternatives to headless browsers that can work with proxies.
Here is the code I'm using:
It appears to be working fine, according to the console window my proxyType is set to "none" and the httpProxy to the ip of the proxy.
But I got suspicious to if it was acctually working so I had it connect to a random IP-checking website and take a screenshot. It showed my real IP.
I'm now completely clueless as to what might be wrong with it. Alternativly I would appreciate alternatives to headless browsers that can work with proxies.
Here is the code I'm using:
Code:
PhantomJSDriverService service = PhantomJSDriverService.CreateDefaultService();
service.IgnoreSslErrors = true;
service.SslProtocol = "any";
var options = new PhantomJSOptions();
options.AddAdditionalCapability(CapabilityType.Proxy, new Dictionary<string, string>
{
{"proxyType", "none"},
{"httpProxy", proxyL}
});