Yahoo BrowserPlus implementation.

Yahoo BrowserPlus implementation. This runtime supports these features: dragdrop, jpgresize, pngresize.

Initializes the browserplus runtime.

Initializes the browserplus runtime.
Uploader instance that needs to be initialized.
Callback to execute when the runtime initializes or fails to initialize. If it succeeds an object with a parameter name success will be set to true.

FlashRuntime implementation.

FlashRuntime implementation. This runtime supports these features: jpgresize, pngresize, chunks.

Initializes the upload runtime.

Initializes the upload runtime. This method should add necessary items to the DOM and register events needed for operation.
Uploader instance that needs to be initialized.
Callback to execute when the runtime initializes or fails to initialize. If it succeeds an object with a parameter name success will be set to true.

Gears implementation.

Gears implementation. This runtime supports these features: dragdrop, jpgresize, pngresize, chunks.

Initializes the upload runtime.

Initializes the upload runtime.
Uploader instance that needs to be initialized.
Callback to execute when the runtime initializes or fails to initialize. If it succeeds an object with a parameter name success will be set to true.

HTML4 implementation.

HTML4 implementation. This runtime has no special features it uses an form that posts files into an hidden iframe.

Initializes the upload runtime.

Initializes the upload runtime.
Uploader instance that needs to be initialized.
Callback to execute when the runtime initializes or fails to initialize. If it succeeds an object with a parameter name success will be set to true.

HMTL5 implementation.

HMTL5 implementation. This runtime supports these features: dragdrop, jpgresize, pngresize.

Initializes the upload runtime.

Initializes the upload runtime.
Uploader instance that needs to be initialized.
Callback to execute when the runtime initializes or fails to initialize. If it succeeds an object with a parameter name success will be set to true.

Silverlight implementation.

Silverlight implementation. This runtime supports these features: jpgresize, pngresize, chunks.

Initializes the upload runtime.

Initializes the upload runtime. This runtime supports these features: jpgresize, pngresize, chunks.
Uploader instance that needs to be initialized.
Callback to execute when the runtime initializes or fails to initialize. If it succeeds an object with a parameter name success will be set to true.

Uploader class, an instance of this class will be created for each upload field.

Uploader class, an instance of this class will be created for each upload field.
var uploader = new plupload.Uploader({ runtimes : 'gears,html5,flash', browse_button : 'button_id' });

uploader.bind('Init', function(up) { alert('Supports drag/drop: ' + (!!up.features.dragdrop)); });

uploader.bind('FilesAdded', function(up, files) { alert('Selected files: ' + files.length); });

uploader.bind('QueueChanged', function(up) { alert('Queued files: ' + uploader.files.length); });

uploader.init();

Constructs a new uploader instance.

Constructs a new uploader instance.
Initialization settings, to be used by the uploader instance and runtimes.
Current state of the total uploading progress. This one can either be plupload.STARTED or plupload.STOPPED. These states are controlled by the stop/start methods. The default value is STOPPED. Current runtime name. Map of features that are available for the uploader runtime. Features will be filled before the init event is called, these features can then be used to alter the UI for the end user. Some of the current features that might be in this map is: dragdrop, chunks, jpgresize, pngresize. Current upload queue, an array of File instances. Object with name/value settings. Total progess information. How many files has been uploaded, total percent etc. Unique id for the Uploader instance. Initializes the Uploader instance and adds internal event listeners. Refreshes the upload instance by dispatching out a refresh event to all runtimes. This would for example reposition flash/silverlight shims on the page. Starts uploading the queued files. Stops the upload of the queued files. Returns the specified file object by id. File id to look for. File object or undefined if it wasn't found; Removes a specific file. File to remove from queue. Removes part of the queue and returns the files removed. This will also trigger the FilesRemoved and QueueChanged events. (Optional) Start index to remove from. (Optional) Lengh of items to remove. Array of files that was removed. Dispatches the specified event name and it's arguments to all listeners. Event name to fire. arguments to pass along to the listener functions. Adds an event listener by name. Event name to listen for. Function to call ones the event gets fired. Optional scope to execute the specified function in. Removes the specified event listener. Name of event to remove. Function to remove from listener. Removes all event listeners. Destroys Plupload instance and cleans after itself. Fires when the current RunTime has been initialized. Uploader instance sending the event. Fires after the init event incase you need to perform actions there. Uploader instance sending the event. Fires when the silverlight/flash or other shim needs to move. Uploader instance sending the event. Fires when the overall state is being changed for the upload queue. Uploader instance sending the event. Fires when a file is to be uploaded by the runtime. Uploader instance sending the event. File to be uploaded. Fires when just before a file is uploaded. This event enables you to override settings on the uploader instance before the file is uploaded. Uploader instance sending the event. File to be uploaded. Fires when the file queue is changed. In other words when files are added/removed to the files array of the uploader instance. Uploader instance sending the event. Fires while a file is being uploaded. Use this event to update the current file upload progress. Uploader instance sending the event. File that is currently being uploaded. Fires while a file was removed from queue. Uploader instance sending the event. Array of files that got removed. Fires while when the user selects files to upload. Uploader instance sending the event. Array of file objects that was added to queue/selected by the user. Fires when a file is successfully uploaded. Uploader instance sending the event. File that was uploaded. Object with response properties. Fires when file chunk is uploaded. Uploader instance sending the event. File that the chunk was uploaded for. Object with response properties. Fires when all files in a queue are uploaded. Uploader instance sending the event. Array of file objects that was added to queue/selected by the user. Fires when a error occurs. Uploader instance sending the event. Contains code, message and sometimes file and other details. Fires when destroy method is called. Uploader instance sending the event.

File instance.

File instance.
Name of the file.
File size.

Constructs a new file instance.

Constructs a new file instance.
Unique file id.
File name.
File size in bytes.
File id this is a globally unique id for the specific file. File name for example "myfile.gif". File size in bytes. Number of bytes uploaded of the files total size. Number of percentage uploaded of the file. Status constant matching the plupload states QUEUED, UPLOADING, FAILED, DONE.

Runtime class gets implemented by each upload runtime.

Runtime class gets implemented by each upload runtime.

Initializes the upload runtime.

Initializes the upload runtime. This method should add necessary items to the DOM and register events needed for operation.
Uploader instance that needs to be initialized.
Callback function to execute when the runtime initializes or fails to initialize. If it succeeds an object with a parameter name success will be set to true.

Runtime class gets implemented by each upload runtime.

Runtime class gets implemented by each upload runtime.

Constructs a queue progress.

Constructs a queue progress.
Total queue file size. Total bytes uploaded. Number of files uploaded. Number of files failed to upload. Number of files yet to be uploaded. Total percent of the uploaded bytes. Bytes uploaded per second. Resets the progress to it's initial values.

Plupload class with some global constants and functions.

Plupload class with some global constants and functions.
// Encode entities console.log(plupload.xmlEncode("My string &lt;&gt;"));

// Generate unique id console.log(plupload.guid());
Inital state of the queue and also the state ones it's finished all it's uploads. Upload process is running File is queued for upload File is being uploaded File has failed to be uploaded File has been uploaded successfully Generic error for example if an exception is thrown inside Silverlight. HTTP transport error. For example if the server produces a HTTP status other than 200. Generic I/O error. For exampe if it wasn't possible to open the file stream on local machine. Generic I/O error. For exampe if it wasn't possible to open the file stream on local machine. Initialization error. Will be triggered if no runtime was initialized. File size error. If the user selects a file that is to large it will be blocked and an error of this type will be triggered. File extension error. If the user selects a file that isn't valid according to the filters setting. Mime type lookup table. Extends the specified object with another object. Object to extend. Multiple objects to extend with. Same as target, the extended object. Cleans the specified name from national characters (diacritics). The result will be a name with only a-z, 0-9 and _. String to clean up. Cleaned string. Adds a specific upload runtime like for example flash or gears. Runtime name for example flash. Object containing init/destroy method. Generates an unique ID. This is 99.99% unique since it takes the current time and 5 random numbers. The only way a user would be able to get the same ID is if the two persons at the same exact milisecond manages to get 5 the same random numbers between 0-65535 it also uses a counter so each call will be guaranteed to be page unique. It's more probable for the earth to be hit with an ansteriod. You can also if you want to be 100% sure set the plupload.guidPrefix property to an user unique key. Virtually unique id. Formats the specified number as a size string for example 1024 becomes 1 KB. Size to format as string. Formatted size string. Returns the absolute x, y position of an Element. The position will be returned in a object with x, y fields. HTML element or element id to get x, y position from. Optional root element to stop calculations at. Absolute position of the specified element object with x, y fields. Parses the specified size string into a byte value. For example 10kb becomes 10240. String to parse or number to just pass through. Size in bytes. Encodes the specified string. String to encode. Encoded string. Forces anything into an array. Object with length field. Array object containing all items.