Project

General

Profile

Uploading binary data to custom javascript

Added by Wolfram Strothmann almost 11 years ago

Hi guys,

which would be the proper way to efficiently upload binary data to custom JavaScript? Due to amount and character of data JSON is not suitable.. I found this thread, which uses WMemoryResource + XHR:

http://redmine.emweb.be/boards/1/topics/4546?r=4558#message-4558

The solutions looks nice to me. However, it seems to be highly interconected to WGLWidget and I would like to use such infrastructure with another custom widget. There something that could be used out-of-the box, in another place of the Wt lib, or would I have to reimplement this taking the above mentioned thread as guide?

Thanks,

Wolf


Replies (1)

RE: Uploading binary data to custom javascript - Added by Wim Dumon almost 11 years ago

Hi Wolfram,

I'm afraid that the binary data upload that we use for WGLWidget is indeed limited to WGLWidget. The good news is that you may be able to reuse the ArrayBufferPreloader functionality located in web/skeleton/Wt.js to asynchronously load your URLs. This is internal/undocumented API, thus may change without warning...

Best regards,

Wim.

    (1-1/1)