iosasihttprequestasiformdatarequest

ASIFormDataRequest POST does not working


I have included all the necessary files in my app (.h and .m files as listed in here) Then I manually added .m files to compile sources and I run my code.

I run my app but nothing went on my server. Server on scripts works fine because I use it in other android apps so it does not have a problem.

Here is the code I used in ViewDidLoad

NSURL *url=[NSURL URLWithString:@"www.myurl.php"];
    ASIFormDataRequest *request=[ASIFormDataRequest requestWithURL:url];
    [request setDelegate:self];
    [request setPostValue:@"test@gmail.com" forKey:@"email"];
    [request setPostValue:@"5678" forKey:@"code"];
    [request setPostValue:@"Demo" forKey:@"table"];
    [request setPostValue:@"testname" forKey:@"name"];

Do I have to add anything?

Here is my imports:

#import "ASIHTTPRequest.h"
#import "ASIFormDataRequest.h"

Solution

  • have you tried starting your request?

        [request startAsynchronous];