ajax - IE striping headers from HTTP POST request to S3 -


i'm doing straight-to-s3 multipart file upload via ajax. works fine under browsers ie.

s3 requires authorization http header in each post request contains signature of file slice being uploaded.

it appears ie strips out header request, yielding 403 response. what's more funny ie not strip custom s3 header: x-amz-date.

any idea how can force 'authorization' header in?

as requested, here code :

initiateupload: function() {   var response = this.sign({method:'post', path: this.key + '?uploads'});   this.request({     method: 'post',     url: response.url,     headers: {       'x-amz-date': response.date,       'authorization': response.signature     },     onload: this.uploadparts.bind(this)   }); },  request: function(params){   var xhr = new xmlhttprequest();   if (params.onload) xhr.addeventlistener("load", params.onload, false);   if (params.onuploadstart) xhr.upload.onloadstart = params.onuploadstart;   if (params.onuploadprogress) xhr.upload.onprogress = params.onuploadprogress;   xhr.open(params.method, params.url, true);   (h in params.headers)     xhr.setrequestheader(h, params.headers[h]);   xhr.send(params.body); }, 


Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -