Questions tagged [asiformdatarequest]
100 questions
12
votes
3 answers
Converting NSArray -> JSON -> NSData -> PHP server ->JSON representation
I am converting an Array of NSDictionaries to JSON data with the following...
Create my data...
NSMutableArray *arrayOfDicts = [[NSMutableArray alloc] init];
for (int i = 0; i < 2; i++) {
NSDictionary *dict = [NSDictionary…

Eric
- 5,671
- 5
- 31
- 42
3
votes
1 answer
ASIHTTPRequest asynchronously request causes EXC_BAD_ACCESS when using ARC
I am using ARC (no, this is not NDA).
I Have a TableView, and in the didSelectRowAtIndexPath Method called from the Delegate I create a new Object, Subclass of UIViewController.
- (void)tableView:(UITableView *)tableView…

brokedid
- 879
- 2
- 10
- 35
3
votes
1 answer
Response for Registering on Wordpress Site through iPhone
I am writing an app that displays content from a Wordpress Site, and also allows reading of comments as well as posting comments. I am handling logging in to leave a comment and posting a comment via XML-RPC. All that is working quite well. However,…

MarkPowell
- 16,482
- 7
- 61
- 77
3
votes
0 answers
How to debug terminate_handler unexpectedly threw an exception?
I'm working on a project which uses ASIFormDataRequest to access the network and here is my code:
NSMutableString *url = [[NSMutableString alloc] initWithCapacity:10];
[url appendString:LOGINURL];
NSURL* nurl = [NSURL…

Don_Chen
- 987
- 2
- 8
- 16
3
votes
1 answer
iOS gzip Compression to PHP
I'm sending a large amount of text to my webpage by POST that's received by PHP. It's approximately 500kb - 1.5 mb. The problem with this, is that it's very repetitive data and I'd like to compress it. The data looks like this,…

user1492744
- 33
- 3
3
votes
1 answer
how to upload image by using asiformdatarequest
I intend to upload image to server using asiformdatarequest.my code like:
UIImage *image = [UIImage imageNamed:@"testicon.jpg"];
NSData *imgData = [[NSData alloc] initWithData:UIImageJPEGRepresentation((image), 0.5)];
NSURL *url = [NSURL…

Tan
- 179
- 3
- 16
3
votes
1 answer
Accessing a property from a ^block causes silly behaviour
I've ran into some issues using ^blocks in Objective-C. I'm trying to set an instance variable from within a block - I've read through some Apple documentation on the topic, and I feel I have tried everything.
@interface MyClass
{
// I have…

Joakim Stien
- 45
- 4
2
votes
1 answer
ASIFormDataRequest - iOS Application. How do I RETRIEVE a post variable
So I have this url that leads to a .php
So far I managed to retrieve every single thing except the actual XML that I want. the XML is stored in a variable called _xml.
if($this->outMethod=="" || $this->outMethod=="POST") //Default to…

Edward Julius
- 21
- 2
2
votes
1 answer
iOS : -[__NSCFDictionary _expandedCFCharacterSet]: error
I am working on iOS application.In one scenario I am sending phone number and some text message to server like this
- (void)postData:(NSString *)message :(NSString *)mobileno
{
NSLog(@"postData is called");
@try
{
NSString *urlString =…
user2299177
2
votes
1 answer
JSON Request Working with NSURLRequest but not with ASIFormDataRequest
I am sending two JSON dictionaries to an url. This is working with NSURLRequest but not with ASIFormDataRequest. When sending the same request with ASIFormDataRequest it shows the following error -
{"Response":"Error","Code":"400","Detail":"Unable…

Namit Gupta
- 796
- 9
- 20
2
votes
2 answers
Sending Mp4 Video to PHP server via ASIFormDataRequest
Here I am sending the file path or file with some parameters. But the server didn't get the video. So any problem in that code? Or anything you want to add something. Then please tell me. Any delegate method you want to tell me where I get error or…

Prabhjot Singh Gogana
- 1,408
- 1
- 14
- 39
2
votes
1 answer
Pass NSString to PHP POST Variable
If I have a php file on my site, how could I pass an NSString to a POST variable (with objective-c) so I can echo it onto the page? I am new to php, so sorry if this is obvious.
Using ASIFormDataRequest:
NSURL *myURl = [[NSURL alloc]…

Imirak
- 1,323
- 11
- 21
1
vote
2 answers
ASIFormDataRequest works fine on iPhone emulator but not on device
I am using ASIFormDataRequest to send a POST request and at the same time upload a couple pictures. Strangely, the same request just worked fine on emulator but not on the real device. And I am getting 400 returned from server side for the device…

tom
- 14,273
- 19
- 65
- 124
1
vote
1 answer
Partial Upload Error when sending video through ASIFormDataRequest on iOS
I'm submitting video from my iOS app to my server, and receiving a PHP error code 3 - 'The uploaded file was only partially uploaded.'. However, this is only occurring some times and I haven't found a pattern with it yet. I'm using…

adamame
- 188
- 11
1
vote
1 answer
EXC_BAD_ACCESS in ASIHTTPRequest / ASIFormDataRequest
I am running into issues using ASIFormDataRequest. The request seems to be made but when I try to access the request once it has completed I get an EXC_BAD_ACCESS error. After looking around I can see no issue with what I'm doing hence me turning…

Chris
- 26,744
- 48
- 193
- 345