http://api.weibo.com/2/users/show.json?uid=1904178193&access_token=2.00zBrJ2EjQ8zzC15a429a8ff2pybUD&source=2045436852
PS,重點是要加上appkey,但這邊很GY害我搞很久的點是,它用source代表appkey,降子取名誰知道啊!翻桌
//20140121
PS,突然發現他的網址改成https了,現在用http開頭是不會通的
當你要跟微博互動時,分為下面二個部份
一、還沒拿到Token時,要利用微博App去跟微博要Token
#pragma mark- WeiboSDKDelegate
//微博App來跟我們寫的App要資料,會觸發這裡,你可以透過[WeiboSDK sendResponse:]回傳資料回去
- (void)didReceiveWeiboRequest:(WBBaseRequest *)request
//這裡是用來接,微博App收到我們的請求的所發出的callback
- (void)didReceiveWeiboResponse:(WBBaseResponse *)response
#pragma mark- WBHttpRequestDelegate
二、當拿到Token以後,就不用透過微博App,而可以直接HttpRequest跟微博互動
//當你用這個方法去呼叫時[WBHttpRequest requestWithAccessToken:...],就會call back回下面的Delegate
#pragma mark- WBHttpRequestDelegate
-(void)alertView:(UIAlertView*)alertView clickedButtonAtIndex:(NSInteger)buttonIndex
- (void)request:(WBHttpRequest *)request didFinishLoadingWithResult:(NSString *)result
沒有留言:
張貼留言