Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MGTwitter is not working

I don't want default twitter to open because it should be compatible with ios < 5 also .

I've used MGTwitterEngine. But it doesn't post tweets. Before few days it was working fine with ios5 too. But now it's not working. I think twitter demo url is depreceated , or not supported with ios5 & 6. What could be the reason? while posting something to twitter the request gets failed & I'm gettiing following error :

Error Domain=HTTP Code=404 "The operation couldn’t be completed. (HTTP error 404.)

Any help would be appreciated !!

like image 305
Niru Mukund Shah Avatar asked Nov 27 '22 04:11

Niru Mukund Shah


2 Answers

Twitter deprecated API version 1 url.
In MGTwitterEngine.h line 40 change

#define TWITTER_DOMAIN          @"twitter.com"

to

#define TWITTER_DOMAIN          @"api.twitter.com/1"

More info https://dev.twitter.com/discussions/10803

like image 123
Or Arbel Avatar answered Dec 11 '22 11:12

Or Arbel


Modifications... 1. Change the TWTTER_DOMAIN in the MGTwitterEngine.m line 40 (pat posted). 2. Chenge the OAuthConsumer.h remove all OAuthconsumer strings. 3. Chenge the HTTP url with SA_OAuthTwitterEngine.m line 65~67, add the api string before twtter.com

like image 28
yun Avatar answered Dec 11 '22 09:12

yun