This example replaced a specific div with a the jQuery uploader queue widget. It will automatically check for different runtimes in the configured order, if it fails it will not convert the specified element.

Your browser doesn't have Flash, Silverlight or HTML5 support.


<div id="uploader">
	<p>Your browser doesn't have Flash, Silverlight or HTML5 support.</p>
</div>

<script type="text/javascript">
// Initialize the widget when the DOM is ready
$(function() {
	// Setup html5 version
	$("#uploader").pluploadQueue({
		// General settings
		runtimes : 'html5,flash,silverlight,html4',
		url : "/examples/upload",
		
		chunk_size : '1mb',
		rename : true,
		dragdrop: true,
		
		filters : {
			// Maximum file size
			max_file_size : '10mb',
			// Specify what files to browse for
			mime_types: [
				{title : "Image files", extensions : "jpg,gif,png"},
				{title : "Zip files", extensions : "zip"}
			]
		},

		// Resize images on clientside if we can
		resize: {
			width : 200, 
			height : 200, 
			quality : 90,
			crop: true // crop to exact dimensions
		},


		// Flash settings
		flash_swf_url : '/plupload/js/Moxie.swf',
	
		// Silverlight settings
		silverlight_xap_url : '/plupload/js/Moxie.xap'
	});
});
</script>

Fork me on GitHub