Edit - title was previously
OneDrive Web picker SDK (Javascript) cannot choose/open file on mobile device
Auto email from SO suggests I change title as bounty period expired.
I have created a OneDrive picker in a mobile friendly website according to these instructions https://dev.onedrive.com/sdk/javascript-picker-saver.htm and it works fine on a Windows desktop.
However on a mobile browser (Android Browser & Chrome on Android 4.2, and Safari on iOS 7) the picker launches and logs me in OK, I can see the files, but when I tap to select a file the "Open" button remains disabled.
Edit, just to clarify : I do not want to upload a file to OneDrive. I want to pick a file already in my OneDrive account and pass its URL back to the page. So that I can send that URL to my server and have the server fetch the file
If I long press on my selected file a content (by that I mean like a right click menu in Windows) menu appears, with an "Open" option - choosing this just seems to make Onedrive re-load.
My code is:
<script type="text/javascript" src="https://js.live.net/v5.0/OneDrive.js" id="onedrive-js" client-id="0000000011111111"></script>
<script type="text/javascript">
var pickerOptions = {
success: function(files) {
console.log(files);
document.getElementById("cloud_cv_source_input").value = "onedrive" ;
document.getElementById("cloud_cv_file_url_input").value = files.values[0].link ;
document.getElementById("cloud_cv_file_name_input").value = files.values[0].fileName;
document.getElementById("cloud_cv_file_size_input").value = files.values[0].size;
},
cancel: function() {
// handle when the user cancels picking a file
},
linkType: "downloadLink", // or "downloadLink",
multiSelect: false // or true
}
function launchOneDrive()
{
OneDrive.open(pickerOptions);
}
</script>
I did see this at the end of the docs:
The OneDrive picker and saver supports the following web browsers:
Internet Explorer 9+
Latest version of Chrome
Latest version of Firefox
Latest version of Safari
So assume this SDK is just for desktop sites, is this correct, and if so, what should I use for a mobile site? I know there are SDK's for Android and iOS but I'm not making a native app.
Thanks.