Open prabhupravin opened 6 years ago
As far as i can see, at this moment it is not possible. Possible solutions: 1: fork the project and add a setUrl() method in DmUploader.prototype.methods, make sure to check if upload widget is idle
2: initialize 2 uploaders on different divs, hide or show the divs on radio button change
Replace
// Ajax Submit
file.jqXHR = $.ajax({
url: file.widget.settings.url,
to
var _url = '';
if( typeof(file.widget.settings.url) === 'function'){
_url = file.widget.settings.url();
}else{
_url = file.widget.settings.url;
}
// Ajax Submit
file.jqXHR = $.ajax({
url: _url,
Then
$('.xxxx').dmUploader({
url: function(){
return url + '?id=' + $('.yyyy').val();
},
$('#drag-and-drop-zone').dmUploader().data().settings.url=[insert url here];
$('#drag-and-drop-zone').dmUploader().data().settings.url=[insert url here];
Doesn't work for me.
Hi,
i might need to upload a file to different URLs basis of a radio button selected on screen
for e.g. if CSV is selected then i upload to 'upload/csv' if XLS is selected then i uploads to 'upload/xls'
is this possible in the current release?
Regards, Pravin