我有一個網站,需要NTLM身份驗證,所以我創建了一個Firefox配置文件:如何在Firefox
FirefoxProfile profile = new FirefoxProfile();
profile.SetPreference("network.http.phishy-userpass-length", 255);
profile.SetPreference("network.automatic-ntlm-auth.trusted-uris", uri.Host);
profile.SetPreference("network.negotiate-auth.delegation-uris", uri.Host);
profile.SetPreference("network.negotiate-auth.trusted-uris", uri.Host);
driver = new FirefoxDriver(profile);
然後我轉到頁與GoToUrl
方法,去罰款,但當我打電話Refresh
- 驗證彈出窗口。谷歌搜索I found它發生,如果調用「強制刷新」,如「Ctrl + F5」,並且確實如此,即使手動執行。那麼,問題是如何執行純刷新而不是強制刷新?
在此先感謝
我不得不使用'IJavaScriptExecutor'我在C#來的,但它的工作,非常感謝 –