Hi Paulo! uploadFileIntoInputField will work only with "input" type html elements like ' input id="bla bla" '. In this case we can easily use sendKeys() method:
inputHtmlElem.sendKeys(absolutePath)
BUT, if html element is not "input", neither uploadFileIntoInputField nor inputHtmlElem.sendKeys(absolutePath) won't work.
Workaround I described in the post is a little bit complicated...But it helps in cases when you need to interact with not "input" html elements to upload smth to the web site :)
Hi Paulo! uploadFileIntoInputField will work only with "input" type html elements like ' input id="bla bla" '. In this case we can easily use sendKeys() method:
BUT, if html element is not "input", neither uploadFileIntoInputField nor inputHtmlElem.sendKeys(absolutePath) won't work.
Workaround I described in the post is a little bit complicated...But it helps in cases when you need to interact with not "input" html elements to upload smth to the web site :)
Thanks to explain Valeria, nice post :D