Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

estimated time left
  • hey guys, is there any way to show the estimated time left?
    i tried modifying my code but it didn't work...

    if someone could help me with that it would be great.

    thanks.
  • Simply add this
    if (event.data.toDisplay == 'timeLeft') displayData = ' - ' + Math.round((fileObj.size/1024 - data.bytesLoaded/1024) / data.speed) + ' second(s) left';

    after
    if (event.data.toDisplay == 'percentage') displayData = ' - ' + data.percentage + '%';
    if (event.data.toDisplay == 'speed') displayData = ' - ' + data.speed + 'KB/s';


    While implementing use
    'displayData' : 'timeLeft'


    Example:
    $(document).ready(function() {
    $('#fileInput').uploadify({
    'uploader' : 'uploadify.swf',
    'script' : 'uploadify.php',
    'cancelImg' : 'cancel.png',
    'auto' : true,
    'folder' : '/uploads',
    'displayData' : 'timeLeft'
    });
    });


    Hope that solves the problem ;)