When i a selecting a file i need to get full path of the file like
"file:///C:/Users/prabhuvignesh/Desktop/sample.jpg"
this.
is this possible by using jquery?
$("#ID").val();
gives file name and i need fill path along with all attribute like size, extension, etc..!
i need this for cordova plugin called "filetransfer" where
var win = function (r) {
console.log("Code = " + r.responseCode);
console.log("Response = " + r.response);
console.log("Sent = " + r.bytesSent);
}
var fail = function (error) {
alert("An error has occurred: Code = " + error.code);
console.log("upload error source " + error.source);
console.log("upload error target " + error.target);
}
var options = new FileUploadOptions();
options.fileKey = "file";
options.fileName = fileURL.substr(fileURL.lastIndexOf('/') + 1);
options.mimeType = "text/plain";
var params = {};
params.value1 = "test";
params.value2 = "param";
options.params = params;
var ft = new FileTransfer();
ft.upload(fileURL, encodeURI("http://some.server.com/upload.php"), win, fail, options);
this needs file path (fileURL), so how can i get it..? any alternate approaches are also welcome.