Group
Extension

Matches 2

Catalyst-Plugin-UploadProgress ( B/BO/BOBTFISH/Catalyst-Plugin-UploadProgress-0.06.tar.gz, BOBTFISH, 2012; MetaCPAN )
Catalyst-Plugin-UploadProgress/lib/Catalyst/Plugin/UploadProgress.pm ( view source; MetaCPAN )
if the URI query string is ?progress_id=<id> intercept the request
    # and display the progress JSON.
    my $query = $c->req->uri->path_query;
    if ( $c->req->method eq 'GET' && $query =~ m{\?pro

        };
    }

    # format the progress data as JSON
    my $json   = '{"size":%d,"received":%d,"aborted":%d}';
    my $output = sprintf $json, 
        $progress->{size},
        $progress->{rec
no-cache, must-revalidate, post-check=0, pre-check=0' );

    $c->response->content_type( 'text/x-json' );
    $c->response->body( $output );
}

sub upload_progress_javascript {
    my $c = shift;

  
Catalyst-Plugin-UploadProgress ( B/BO/BOBTFISH/Catalyst-Plugin-UploadProgress-0.06.tar.gz, BOBTFISH, 2012; MetaCPAN )
Catalyst-Plugin-UploadProgress/lib/Catalyst/Plugin/UploadProgress/Static.pm ( view source; MetaCPAN )
ans that text/html gets picked first
    req.setRequestHeader(
        'Accept', 
        'text/x-json; q=1.1'
    );
    req.onreadystatechange = function() {
        if (req.readyState == 4)
       
);
    };
    req.send(null);
}

function handleUploadProgressResults(results) {

    var state = JSON.parse(results);

    if ( state != undefined ) {

        state.starttime       = progress.startt
 data = data();
    else if (typeof data == 'string') {
        Ajax.get(data, function(r) { proc(JSON.parse(r)) });
        return;
    }

    return proc(data);
}

//--------------------------------

Powered by Groonga
Maintained by Kenichi Ishigaki <ishigaki@cpan.org>. If you find anything, submit it on GitHub.