All Downloads are FREE. Search and download functionalities are using the official Maven repository.

META-INF.resources.bower_components.blueimpfileupload.js.jquery.fileupload-audio.min.js Maven / Gradle / Ivy

Go to download

File Upload widget with multiple file selection, drag and drop support, progress bar, validation and preview images, audio and video for jQuery. Supports cross-domain, chunked and resumable file uploads. Works with any server-side platform (Google App Engine, PHP, Python, Ruby on Rails, Java, etc.) that supports standard HTML form file uploads.

There is a newer version: 1.2.2.1-jre17
Show newest version
(function(a){if(typeof define==="function"&&define.amd){define(["jquery","load-image","./jquery.fileupload-process"],a)}else{if(typeof exports==="object"){a(require("jquery"),require("blueimp-load-image/js/load-image"),require("./jquery.fileupload-process"))}else{a(window.jQuery,window.loadImage)}}}(function(a,b){a.blueimp.fileupload.prototype.options.processQueue.unshift({action:"loadAudio",prefix:true,fileTypes:"@",maxFileSize:"@",disabled:"@disableAudioPreview"},{action:"setAudio",name:"@audioPreviewName",disabled:"@disableAudioPreview"});a.widget("blueimp.fileupload",a.blueimp.fileupload,{options:{loadAudioFileTypes:/^audio\/.*$/},_audioElement:document.createElement("audio"),processActions:{loadAudio:function(g,d){if(d.disabled){return g}var e=g.files[g.index],c,f;if(this._audioElement.canPlayType&&this._audioElement.canPlayType(e.type)&&(a.type(d.maxFileSize)!=="number"||e.size<=d.maxFileSize)&&(!d.fileTypes||d.fileTypes.test(e.type))){c=b.createObjectURL(e);if(c){f=this._audioElement.cloneNode(false);f.src=c;f.controls=true;g.audio=f;return g}}return g},setAudio:function(d,c){if(d.audio&&!c.disabled){d.files[d.index][c.name||"preview"]=d.audio}return d}}})}));




© 2015 - 2025 Weber Informatics LLC | Privacy Policy