I am working on an existing project. I use the jQuery Uploadify plugin to upload files. The following button code is used to upload files:
<div>
<input width="167" type="file" height="47" name="file_upload" class="file_upload" id="file_upload" style="display: none;">
<object width="167" height="47" type="application/x-shockwave-flash" data="/uploadify/uploadify.swf" id="file_uploadUploader" style="visibility: visible;"><param name="quality" value="high">
<param name="wmode" value="transparent">
<param name="allowScriptAccess" value="sameDomain">
<param name="flashvars" value="uploadifyID=file_upload&pagepath=/en/media-maker/&script=/en/media-maker/upload/file&folder=&scriptData=level%3D1%26folderid%3D15%26symfony%3Dbtt461h1nor36k2taotp6jhku4&width=167&height=47&wmode=transparent&method=POST&queueSizeLimit=20&simUploadLimit=1&hideButton=true&fileDesc=Image / Video / Audio&fileExt=*.jpg;*.jpeg;*.gif;*.png;*.bmp;*.svg;*.avi;*.divx;*.dvx;*.dv;*.asf;*.asx;*.3gp;*.3g2;*.3ivx;*.3vx;*.mov;*.mp4;*.m4v;*.mpg;*.mpeg;*.qt;*.rm;*.swf;*.wmv;*.mkv;*.mts;*.part;*.mp3;&multi=true&auto=true&sizeLimit=524288000&fileDataName=Filedata&queueID=uploadList">
</object>
</div>
My problem is that this button appears very late when I refresh the webpage. This button appears only after the whole page is uploaded. Sometimes this button does not appear on some browsers and slow internet connection. How do I make it appear faster?
Thanks
If the <object>
is your button and it's some sort of .swf flash file ... well the browser can't display it until it downloads the whole thing from /uploadify/uploadify.swf
... Not to mention it has to fire up the flash plugin just to render a simple button. This is why it's slow.
I can't say I would ever advocate using a flash file for a button when CSS has is now so well-supported by so many browsers. I might go so far as to call it completely nonsensical.