--
You received this message because you are subscribed to the Google Groups "webdriver" group.
To view this discussion on the web visit https://groups.google.com/d/msg/webdriver/-/k6vB4GRmWFkJ.
To post to this group, send email to webd...@googlegroups.com.
To unsubscribe from this group, send email to webdriver+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/webdriver?hl=en.
What OS? With Windows at least, I believe the file upload screen
is under control of the OS, so is not visible to webdriver.
Bill
I am on a Mac with OS X lion. I am using FF5 and using selenium-server standalone 2.9. When I click on the Select Media Button from the parent window, the parent window is greyed out and a file upload window opens which is actually a anchored frame. My problem is actually switching focus on that frame. I have tried digging through various posts here on the forum but still no luck.
Thanks,
Rivlin
Sent from my iPhone
> --
> You received this message because you are subscribed to the Google Groups "webdriver" group.
The problem is that a file upload window is generally an OS level dialogue box, not a JavaScript based in browser one. Selenium cannot interact with these hence why you need to use sendKeys on the input element. This will trigger the workaround behaviour to deal with file uploads.
You’ll need to provide a link to the page or all the HTML for us to try and help you any further.
--
You received this message because you are subscribed to the Google Groups "webdriver" group.
To view this discussion on the web visit https://groups.google.com/d/msg/webdriver/-/_Yn1Xn8SQuEJ.
To post to this group, send email to webd...@googlegroups.com.
To unsubscribe from this group, send email to webdriver+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/webdriver?hl=en.
What happens if you use:
driver.findElement(By.xpath(“//input[@id=’edit-upload’]”)).sendKeys(“c:\myfile.txt”)
In the test you have below it looks like to are passing a path to the file upload, and not a file. I’m also wondering if the square brackets may be causing issues.
--
You received this message because you are subscribed to the Google Groups "webdriver" group.
To view this discussion on the web visit https://groups.google.com/d/msg/webdriver/-/bnj6kvsPxioJ.
To post to this group, send email to webd...@googlegroups.com.
To unsubscribe from this group, send email to webdriver+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/webdriver?hl=en.
Is this HTML inside a frame/iFrame that you haven’t switched to?
In that case you need to switch to the frame first J
Simon
On Mon, Oct 24, 2011 at 8:40 PM, Rivlin Pereira
<rivlin....@gmail.com> wrote:
> Hi Mark/ Luke,
>
> In the HTML snapshot I have posted If i click on the Select Media button and
> then hover over the Library tab it link is
>
> http://xxx.xxx.xxxxx.xx/media/browser?render=media-popup&types%5Baudio%5D=audio&activePlugins=&schemes%5Bnpraudio%5D=npraudio&schemes%5Bnprshared%5D=0&schemes%5Bcsscache%5D=0&schemes%5Bpublic%5D=0&plugins=undefined#media-add-upload;
>
> so to open the frame it just opens up another div and appends the url from
> the form tag which can be seen from this html -
>
> <div class="content">
> <div id="media-browser-tabset"><ul><li><a
> href='#media-tab-upload'><span>Upload</span></a></li><li><a
> href='#media-tab-library'><span>Library</span></a></li></ul> <div
> class="media-browser-tab" id="media-tab-upload">
> <form enctype="multipart/form-data"
> action="/media/browser?render=media-popup&plugins=undefined"
> method="post" id="media-add-upload" accept-charset="UTF-8"><div><div
> class="form-item form-type-file form-item-files-upload">
> <label for="edit-upload">Upload a new file </label>
>
> <input type="file" id="edit-upload" name="files[upload]" size="60"
> class="form-file" />
> <div class="description">Allowed file types: <strong>mp3</strong>.</div>
> </div>
>
> i tried using driver.get(/media/browser?.....) and the frame opens up in
> that url but then i cannot click on the submit button to return back to the
> parent window.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "webdriver" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/webdriver/-/A_UtpSsX8ukJ.
I will try that
Sent from my iPhone