2

我想从 Amazon s3 存储桶中删除文件和文件夹。以下是我的要求,但它不起作用。

     $.ajax({ 
         type: "POST",
         dataType: "jsonp",

         url: "http://s3.amazonaws.com/bucketname/",
          beforeSend: function( xhr ) {
            xhr.setRequestHeader('Action','DELETE');
            xhr.setRequestHeader('AWSAccessKeyId','AWSAccessKeyId');
            xhr.setRequestHeader('signature','signature');
            xhr.overrideMimeType( "application/octet-stream" );
         },
          success: function(data){  alert("IN SUCCESS"); alert(data);  },
          error: function(data) {  alert(data);}

     });
4

0 回答 0