![]() ![]() To download to another folder: FirefoxOptions options = new FirefoxOptions() To download to desktop, change the value in 2nd line to 0: FirefoxOptions options = new FirefoxOptions() Options.addPreference("", "application/octet-stream") To download to folder Downloads: FirefoxOptions options = new FirefoxOptions() mentioned above.įor me, download csv file and found that Content-Type = "application/octet-stream" ![]() WebDriver driver = new FirefoxDriver(options) ĭriver.findElement(By.linkText("IRS Form 872-C")).click() tPreference("pdfjs.disabled", true) // disable the built-in PDF viewer tPreference("", "application/pdf text/plain application/text text/xml application/xml") Then to download a PDF with Firefox: FirefoxOptions options = new FirefoxOptions() The mime type is the Content-Type from the response header:.In the network panel, select the first request.Just like suggested, it's most probably another mime type. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |