我編碼顯示PHPecho
iOS:爲什麼我在Xcode中獲得'Unused variable'?
NSMutableURLRequest *request = [[NSMutableURLRequest alloc]init];
[request setTimeoutInterval:180.0];
[request setURL:[NSURL URLWithString:@"http://localhost:8888/MAMP/signup/getkey.php"]];
[request setHTTPMethod:@"POST"];
NSString *key = [[NSString alloc] initWithData:[NSURLConnection sendSynchronousRequest:request returningResponse:nil error:nil] encoding:NSUTF8StringEncoding];
當我編譯,我有這樣的警告消息:Unused variable key
問題出在哪裏?
謝謝!沒關係 :) – user1659987