asihttprequest

newbie stuck: ASIHTTPRequest - no known class method for selector 'requestWithURL'

北城以北 提交于 2019-12-11 07:54:40
问题 I am referencing ASIHTTPRequest and got it to compile in iOS5 . However when I try to use it: ASIHTTPRequest *request = [ASIHTTPRequest requestWithURL:url]; I get the error no known class method for selector 'requestWithURL'. Also setCacheStoragePolicy and startAsynchronous throw errors. Indeed I can't see that method in the ASIHTTPRequest.m file. What am I missing? This is the latest code download from github . Thanks, John. 回答1: Go to target and check ASIHTTPRequest.m is a part of compiler

clang: error: no such file or directory: ASIAuthenticationDialog.m

余生颓废 提交于 2019-12-11 07:35:55
问题 I have this error: clang: error: no such file or directory: '/Users/usuario/Desktop/echonest-echoprint-ios-sample-b937c04/Classes/ASIHTTP/clang: error: no such file or directory:' I want to run the " echoprint-ios-sample " project and I import the ASIHTTP files I don´t know what is the problem :( Someone can help me? Thanks! 回答1: If you u've deleted any h or m files, go through the project navigation(command + 1) in your xcode, there may be some reference(will be in red color) in that project

ASIHTTPRequest with iPhone 3G

可紊 提交于 2019-12-11 06:39:00
问题 I am using ASIHTTPRequest in my project and i have a problem with iPhone 3G. i send a request to : NSURL* pageURL = [NSURL URLWithString:@"https://accounts.google.com/ServiceLogin?service=sj"]; loginPageRequest = [[ASIHTTPRequest alloc] initWithURL:pageURL]; [loginPageRequest setTimeOutSeconds:30]; [loginPageRequest setDelegate:self]; [loginPageRequest startAsynchronous]; and in other devices i get a responde to : - (void)requestFinished:(ASIHTTPRequest *)request and in iPhone 3G i get a lot

My app crashes when downloading large pdfs (>2MB) in iphone

喜夏-厌秋 提交于 2019-12-11 05:59:55
问题 My app is working fine for downloading small Pdf's and showing them in WebView but when i fetch url of pdfs having size more than 2 MB it crashes everytime. Code :- @implementation SecondViewController @synthesize scrollView,receivedData,myIndicator; - (void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)data { [receivedData appendData:data]; } // Implement viewDidLoad to do additional setup after loading the view, typically from a nib. - (void)viewDidLoad { [super

ASIFormDataRequest upload video works in iPhone simulator but fails with iPhone for files over 1.5 MB

心不动则不痛 提交于 2019-12-11 05:28:37
问题 I am using ASIHTTPFormDataRequest to upload a video file. I know my code works because when I upload a video under 1.5 MB (low quality under 1 minute 40 seconds) on the iPhone it successfully posts. I was convinced it was a server issue so we did every test ever and came back with no success. It wasn't until the other day that I was able to successfully upload a large file within the iPhone simulator. The file was over 5 MB and high quality. So I am forced to belive that it has something to

ASIHTTPRequest memory leaks

拟墨画扇 提交于 2019-12-11 02:53:56
问题 I have a iOS project in which I am using ARC in my own classes, but have ARC turned off in other libraries like ASIHTTPRequest . I'm getting huge memory leaks using the code below to fetch an image from a web server: -(void)buildPhotoView { self.photoLibView.hidden = NO; NSString *assetPathStr = [self.cellData objectForKey:@"AssetThumbPath"]; // get the thumbnail image of the ocPHOTOALBUM from the server and populate the UIImageViews NSURL *imageURL = [NSURL URLWithString:assetPathStr]; _

Upload file onto Server from the IPhone using ASIHTTPRequest

怎甘沉沦 提交于 2019-12-11 01:21:55
问题 I've been trying to upload a file ( login.zip ) using the ASIHTTPRequest libraries from the IPhone onto the inbuilt Apache Server in Mac OS X Snow Leopard. My code is: NSString *urlAddress = [[[NSString alloc] initWithString:self.uploadField.text]autorelease]; NSURL *url = [NSURL URLWithString:urlAddress]; ASIFormDataRequest *request; NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory,NSUserDomainMask, YES); NSString *documentsDirectory = [paths objectAtIndex:0];

iPhone SIGSEGV crash with any level of Optimization using ARC+ASIHTTPRequest

China☆狼群 提交于 2019-12-10 23:57:35
问题 I currently use ASIHTTPRequest for synchronous requests I recently refactored my code to comply with ARC and omit the ASIHTTPRequest class using the compiler flag -fno-objc-arc I have a _mh_execute_header SIGSEGV crash when I use any type of optimization While turning off all optimization allows my app to run - I need to be able to optimize the app using the iOS default settings which use Fastest, Smallest [-Os] Since this is a memory related issue and since the only manually managed memory

How to remove a cell from table

℡╲_俬逩灬. 提交于 2019-12-10 22:25:37
问题 I use asihttprequest to download a file but when the download fails, the cell associated with the file in the table doesn't remove from the tableview. When I swipe to delete, I have this error : * Terminating app due to uncaught exception 'NSRangeException', reason: '* -[NSMutableArray objectAtIndex:]: index 0 beyond bounds for empty array' How can I remove the cell ? MANAGER.h NSMutableArray *contentArray; MANAGER.m - (id)initWithStyle:(UITableViewStyle)style { if (self == [super

Subscript requires size of interface 'NSArray', which is not constant in non-stable ABI

耗尽温柔 提交于 2019-12-10 21:53:21
问题 I'm trying to send information to a server using ASIHTTPRequest and am setting the post values like this: for(int i = 0;i<13;i++){ [request setPostValue:propertyValues[i] forKey:propertyKeys[i]] } propertyValues and propertyKeys are both NSArray objects that hold 13 items each. When I run this, I get the error "Subscript requires size of interface 'NSArray', which is not constant in non-stable ABI" What does this mean? 回答1: It means you're trying to access an NSArray* as if it were an array,