2012-04-27 1 views
0
 uploader= new plupload.Uploader({ 
     runtimes: 'gears,html5,flash,silverlight,browserplus,html4', 
     browse_button: 'pickFile', 
     container: 'FileContainer', 
     max_file_size: '2048mb', 
     url: '<%=Url.Action("testaction", "testcontroller", 
     new { area = "testArea" }) %>', 
     flash_swf_url: flashVideomm, 
     silverlight_xap_url: silverLightmm, 
     multipart: true, 
     multipart_params: { "form": '' 
     }, 
     filters: [ 
       { title: "Excel file", extensions: "xlsx" } 
      ] 
    }); 
    uploader.bind('FileUploaded', function (up, file, info) { 
     // Redirect after successful upload 
     alert(info); 
    }); 

위의 예제에서 "FileUploaded"이벤트는 전혀 발생하지 않습니다. 문제가 무엇인지 잘 모릅니다.Plupload -FileUploaded 이벤트가 실행되지 않음

답변

0

이 방법을 시도해 보셨습니까?

uploader= new plupload.Uploader({ 
     runtimes: 'gears,html5,flash,silverlight,browserplus,html4', 
     browse_button: 'pickFile', 
     container: 'FileContainer', 
     max_file_size: '2048mb', 
     url: 'CHECK THIS AREA', 
     new { area = "testArea" }) %>', 
     flash_swf_url: flashVideomm, 
     silverlight_xap_url: silverLightmm, 
     multipart: true, 
     multipart_params: { "form": ''}, 
     filters: [ 
       { title: "Excel file", extensions: "xlsx" } 
      ], 
     init: 
      { 
      FilesAdded: function (up, files, info?) { alert(files.length); } 
      } 

    }); 

PS 여기에 사본이나 과거 또는 오타가 있습니까? 이것은 JavaScript 문제를 야기 할 것이고 대부분은 bind 및/또는 전체 javaScript 엔진이 멈추는 원인이 될 것입니다.

'<%=Url.Action("testaction", "testcontroller",