vote up 2 vote down star
1

Hello!

I have a variable in javascript containing a string of XML data that I want to upload to a server running ASP.NET MVC.

It works just fine using jQuery.post method. My problem is that the data weights about 5 megabytes so this process could be rather long depending on the bandwidth available between the client and the server. As of now, in the user's perspective, the process feels like nothing is happening because there is no feedback whatsoever.

This upload is part of a workflow in which other somewhat lenghty steps are included, namely to extract the XML from a device. These steps report realtime feedback to the user thanks to the jQuery Progressbar and some client side events. It would make sense to include the upload in the same process and use some similar reporting mechanism.

Any help would be appreciated... thanks in advance!

Marc Lacoursiere RooSoft Computing inc.

flag
Storing 5MB of XML data on the client seems like a bad idea. Is it really necessary to store all that XML on the client at once? – Soviut Jun 14 at 17:14
I recieve the data from a device and I need to send it to the server for it to be stored in a database. I could parse the XML in javascript on client side and send less data but it seems like a complicated operation to me. – RooSoft Jun 14 at 17:29

1 Answer

vote up 2 vote down check

You could break the data into multiple pieces (e.g. 50 kB) and then calculate the progress on the client.

link|flag
Interesting idea... I will try this for sure if I cannot find an easier way. Thanks a lot! – RooSoft Jun 14 at 17:30

Your Answer

Get an OpenID
or

Not the answer you're looking for? Browse other questions tagged or ask your own question.