AutoIt file upload works in normal mode but AutoIt is not working in headless mode
CodePudding user response:
AutoIt can't be used to click on a headless browser. However, if the form is a standard file upload, you should be able to sendKeys() in selenium to send the path of the file to the input.
driver.findElement(By.cssSelector("input[type='file']")).sendKeys("/Users/me/Desktop/file.txt");
CodePudding user response:
I know you are using selenium.
But take a look on: https://github.com/Danp2/au3WebDriver/blob/master/wd_demo.au3
DemoUpload() works on NonHeadless and on Headless mode.
Check this demo and try to do this in similar way in selenium.