You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by "Shazron Abdullah (JIRA)" <ji...@apache.org> on 2012/07/09 23:08:34 UTC

[jira] [Resolved] (CB-1015) File Upload does not send additional fields

     [ https://issues.apache.org/jira/browse/CB-1015?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shazron Abdullah resolved CB-1015.
----------------------------------

       Resolution: Fixed
    Fix Version/s: 2.0.0

Fix commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/commit/95cfc512
                
> File Upload does not send additional fields
> -------------------------------------------
>
>                 Key: CB-1015
>                 URL: https://issues.apache.org/jira/browse/CB-1015
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: iOS
>    Affects Versions: 1.9.0
>         Environment: iOS 5.1.1
>            Reporter: Stephen McKamey
>            Assignee: Shazron Abdullah
>            Priority: Blocker
>              Labels: file_upload, upload
>             Fix For: 2.0.0
>
>
> Similar code using the pattern below used to work in previous versions. Trying to upgrade to the latest and noticed this issue. Cannot seem to work around it. The file binary posts fine but there are no additional fields despite the options object specifying 'params':
> 	var options = new FileUploadOptions();
> 	
> 	options.fileKey = 'file';
> 	options.fileName = imageURI;
> 	options.mimeType = 'image/jpeg';
> 	
> 	options.params = {
> 		key1: 'value1',
> 		key2: 'value2'
> 	};
> 	
> 	new FileTransfer().upload(
> 		imagePath,
> 		remoteURL,
> 		successFn,
> 		errorFn,
> 		options);
> This currently prevents upload to any server which requires a single multipart body.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira