Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9088147
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T21:51:24+00:00 2026-06-16T21:51:24+00:00

I have a JavaScript object with a huge amount of data in it, including

  • 0

I have a JavaScript object with a huge amount of data in it, including several large base64 encoded strings.

We are currently sending the data to the server via a simple ajax POST but since the data is so large the wait time for the user is unacceptable.

For this reason we wish to harness the new html5 file upload features and actually measure the progress as the data is uploaded to the server so that the user is provided with constant feedback during this lengthy process.

In order to use this feature this large array will have to be sent as an actual file rather than as a huge object sent as url params.

Is there any way to either:

A. Convert this object into an actual text file and send it that way.

or

B. Hook into the html5 progress api and actually measure the progress of this standard ajax POST.

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T21:51:25+00:00Added an answer on June 16, 2026 at 9:51 pm

    It’s possible to take a JavaScript object (myData), stringify it into JSON, pack that into a Blob of mimetype JSON, and send that to the server with the HTML5 upload API. You can use the progress (in the progress callback function) to update the value of an HTML5 progress bar.

    var myData = {
        data1: "Huge amount of data",
        data2: "More very large data"
    };
    
    var xhr = new XMLHttpRequest();
    
    xhr.upload.addEventListener('progress', function (e) {
        console.log(100*(e.loaded / e.total) + '%');
    }, false);
    
    xhr.open('POST', 'url', true);
    
    var data = new FormData();
    data.append('file', new Blob([JSON.stringify(myData)],{type:'application/json'}));
    xhr.send(data);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a javascript object which I am encoding to Json and sending data
I have a Javascript object that requires 2 calls out to an external server
I have Javascript object like: var data = { Id: 1, Name: Some name,
I have a JavaScript object called ShippingUI: function ShippingUI(){ ... } It has several
I have two javascript object with data like this: { data: [ { foo:
I have a javascript object that I would like to update with data from
I have a javascript object, which I've added a number of prototyped functions to,
I have a Javascript object created as follows: var ccStatTracker = (function (){ ccmap:{
I have a javascript object like so: var object = [{ id: 1, title:xyz
I have a Javascript object that basically represents a Row in an .NET GridView.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.