[ 
https://issues.apache.org/jira/browse/CB-11118?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16261603#comment-16261603
 ] 

ASF GitHub Bot commented on CB-11118:
-------------------------------------

maverickmishra commented on issue #143: CB-11118: Add support for Array and 
Object params in iOS
URL: 
https://github.com/apache/cordova-plugin-file-transfer/pull/143#issuecomment-346183538
 
 
   With the new features introduced in 
[XMLHttpRequest](https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest),
 this plugin is not needed any more. Migrating from this plugin to using the 
new features of 
[XMLHttpRequest](https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest),
 is explained in this [Cordova blog 
post](https://cordova.apache.org/blog/2017/10/18/from-filetransfer-to-xhr2.html).

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


> Array and object params on upload ignored in ios
> ------------------------------------------------
>
>                 Key: CB-11118
>                 URL: https://issues.apache.org/jira/browse/CB-11118
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: cordova-plugin-file-transfer
>    Affects Versions: 1.5.0
>         Environment: iOS
>            Reporter: Andrew Gaun
>              Labels: easyfix, iOS, triaged
>
> On iOS, CDVFileTransfer.m the method requestForUploadCommand will only allow 
> params objects with selector stringValue and NSString to be included with the 
> request. 
> On Android objects and arrays are turned into strings when used as params
> Example:
> {code:javascript}
>   var fileUploadOptions = new FileUploadOptions();
>   fileUploadOptions.params = {
>     "array": [1,2,3],
>     "object": { 
>       "a": 1
>     },
>     number: 123
>   }
> {code}
> will return from iOS
> {code:javascript}
>   {
>     number: '123'
>   }
> {code}
> and from android
> {code:javascript}
>   {
>     array: '[1,2,3]',
>     object: '{"a":1}',
>     number: '123'
>   }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to