8000 GitHub - imhui/HTTPRequestHelper: Make it easy to use NSURLConnection to do get or post http request.
[go: up one dir, main page]

Skip to content

Make it easy to use NSURLConnection to do get or post http request.

Notifications You must be signed in to change notification settings

imhui/HTTPRequestHelper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

HTTPRequestHelper

Make it easy to use NSURLConnection to do get or post http request.

##sample:

###GET NSDictionary *params = [NSDictionary dictionary]; HTTPRequestHelper *client = [[HTTPRequestHelper alloc] initWithTarget:self selector:@selector(dataDidReceived:)]; [client get:@"http://www.google.com" params:params]; [client release];

- (void)dataDidReceived:(id)data {
	HTTPLOG(@"data: %@", data);
}

###POST

HTTPRequestHelper *client = [[HTTPRequestHelper alloc] initWithTarget:self
                                                         selector:@selector(dataDidReceived:)];
[client post:@"http://www.google.com" params:params];


[client release];

###POST(upload file) HTTPRequestHelper *client = [[HTTPRequestHelper alloc] initWithTarget:self selector:@selector(dataDidReceived:)]; [client post:@"http://www.google.com" params:params data:[NSData data] dataKey:@"data_key"];

[client release];

About

Make it easy to use NSURLConnection to do get or post http request.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
0