I'm trying to use YUI uploader, but I'm not able to open the file dialog window when I click the browse button. I'm following (more or less) the example on Yahoos demo.
Here is my HTML code:
<div id="fileProgress">
<input id="fileName" type="text" size="40" />
<input id="uploaderUI" name="uploaderUI" class="submitButton" type="button" value="Browse" />
<input id="uploadFile" name="uploadFile" class="submitButton" type="button" value="Upload" />
<div id="progressBar"></div>
</div>
And here is my javasctips code:
jQuery(document).ready(function() {
initYUIUpload();
});
function initYUIUpload()
{
YAHOO.widget.Uploader.SWFURL = "wp-includes/js/yui/assets/uploader.swf";
var uploader = new YAHOO.widget.Uploader("uploaderUI");
uploader.addListener('contentReady', handleContentReady);
uploader.addListener('fileSelect',onFileSelect)
uploader.addListener('uploadStart',onUploadStart);
uploader.addListener('uploadProgress',onUploadProgress);
uploader.addListener('uploadCancel',onUploadCancel);
uploader.addListener('uploadComplete',onUploadComplete);
uploader.addListener('uploadCompleteData',onUploadResponse);
uploader.addListener('uploadError', onUploadError);
jQuery('#uploadFile').click(function(){ upload() });
}
UPDATE
I "gave up" using YUI uploader, and I'm using Uploadify now.