javascript - Play audio file on the server side using ElFinder -


i trying play .mp3 file on server side using elfinder. have created 2 instances of elfinder. how should play file 1 of instances on server side? here code

handlers : {                             select : function(event, elfinderinstance) {                                 var selected = event.data.selected;                       if (selected.length>0) {                     var filenamex=elfinderinstance.file(selected[0]).name;                     console.log(filenamex);                      var path=elfinderinstance.path(selected[0]);                     console.log(path);                     if(filenamex.indexof(".mp3") == filenamex.length - 4) {                      console.log("mp3 file");                     }                     }                                }                         },                 lang : 'en',                 customdata : {answer : 42},                 rememberlastdir :false,                 debug:true                }).elfinder('instance'); 

i first try check whether selected file mp3 file or not. if mp3 file should able play it.


Comments

Popular posts from this blog

javascript - AngularJS custom datepicker directive -

javascript - jQuery date picker - Disable dates after the selection from the first date picker -