I am building a file upload progress bar. Currently I have an upload form which returns the current amount of uploaded data. So, it starts at zero, and returns the current size in bits, but I have converted that to bytes.
If I can get the total file size before I upload, and can get the current amount uploaded, and return this dynamically, how could I calculate this so that I can use a 1-100% value for a css width?
I am using the swfupload jquery plugin: http://blogs.bigfish.tv/adam/2009/06/14/swfupload-jquery-plugin