Search Results

Search found 84 results on 4 pages for 'twitterapi'.

Page 1/4 | 1 2 3 4  | Next Page >

  • shell_exec escaping quotes in php for Twitter API

    - by yc10
    I'm (lazily) using shell_exec() to execute a Twitter API Call. shell_exec('curl -u user:password -d "id=3191321" http://api.twitter.com/1/twitterapi/twitterlist/members.xml'); That works fine when I authenticate correctly and put in a number for the id. But when I try to put in a variable ($id), it screws up. $addtolist = shell_exec('curl -u pxlist:Weekend1 -d "id='.$id.'" http://twitter.com/username/twitterlist/members.xml'); I tried flipping the quote types $addtolist = shell_exec("curl -u pxlist:Weekend1 -d 'id=$id' http://twitter.com/username/twitterlist/members.xml"); I tried using double quotes and escaping them $addtolist = shell_exec("curl -u pxlist:Weekend1 -d \"id=$id\" http://twitter.com/username/twitterlist/members.xml"); None of them worked. What am I doing wrong?

    Read the article

  • shell_exec escaping quotes in php for Twitter API --> Getting CURL to work with obscure twitter api

    - by yc10
    I'm using shell_exec() to execute a Twitter API Call. shell_exec('curl -u user:password -d "id=3191321" http://api.twitter.com/1/twitterapi/twitterlist/members.xml'); That works fine when I authenticate correctly and put in a number for the id. But when I try to put in a variable ($id), it screws up. $addtolist = shell_exec('curl -u pxlist:Weekend1 -d "id='.$id.'" http://twitter.com/username/twitterlist/members.xml'); I tried flipping the quote types $addtolist = shell_exec("curl -u pxlist:Weekend1 -d 'id=$id' http://twitter.com/username/twitterlist/members.xml"); I tried using double quotes and escaping them $addtolist = shell_exec("curl -u pxlist:Weekend1 -d \"id=$id\" http://twitter.com/username/twitterlist/members.xml"); None of them worked. What am I doing wrong? EDIT: The purists say I should be using PHP's built in curl methods, not the shell_exec. That's not working either. $url = 'http://twitter.com/user/list/members.xml'; // Set up and execute the curl process $curl_handle = curl_init(); curl_setopt($curl_handle, CURLOPT_URL, "$url"); curl_setopt($curl_handle, CURLOPT_CONNECTTIMEOUT, 2); curl_setopt($curl_handle, CURLOPT_RETURNTRANSFER, 1); curl_setopt($curl_handle, CURLOPT_POST, 1); curl_setopt($curl_handle, CURLOPT_POSTFIELDS, "id=$id"); curl_setopt($curl_handle, CURLOPT_USERPWD, "user:pw"); $buffer = curl_exec($curl_handle); curl_close($curl_handle); It returns bool(false), and doesn't properly update the Twitter List in question (the whole point of the exercise)

    Read the article

  • "Could not authenticate you." -error when using Twitter OAuth.

    - by Martti Laine
    Hello I'm building my first system using Twitters OAuth and have some issues. First, I'm using Abraham's Twitter-class for this and I have followed this tutorial. However, I get these lines on my callback.php: Warning: array_merge() [function.array-merge]: Argument #2 is not an array in C:\xampp\htdocs\twitter\twitterOAuth\OAuth.php on line 301 Warning: strtoupper() expects parameter 1 to be string, array given in C:\xampp\htdocs\twitter\twitterOAuth\OAuth.php on line 373 Oops - an error has occurred. SimpleXMLElement Object ( [request] => /account/verify_credentials.xml [error] => Could not authenticate you. ) Is this problem by Twitter-class, or am I doing something wrong? I have my Consumer Key and Consumer Secret in config.php as tutorial says, but should I store something else? Martti Laine

    Read the article

  • mgtwitterengine and oauth 401 error: Boggled

    - by Jason
    OK... so here is my code: twitterEngine = [[MGTwitterEngine alloc] initWithDelegate:self]; [twitterEngine setConsumerKey:CONSUMER_KEY secret:CONSUMER_SECRET]; accessToken = [twitterEngine getXAuthAccessTokenForUsername:profile.twitterUserId password:profile.twitterPassword]; NSLog(@"Access token: %@", accessToken); the console shows the access token returned just fine (so it seems to work) eg. Access token: C8A24515-0F11-4B5A-8813-XXXXXXXXXXXXXX but instead of accessTokenReceived method being called next on my delegate, it calls requestFailed with a 401. How can I be getting a 401 unauthorized and getting an access token back from the method call?????

    Read the article

  • jQuery.ajax call to Twitter succeeds but returns null for Firefox

    - by Zhami
    I've got code that makes a simple get request to Twitter (search) using jQuery's ajax method. The code works fine on Safari, but fails on Firefox (3.6.3). In the Firefox case, my jQuery.ajax parameters 'success' method is invoked, but the supplied data is null. (In Safari, I receive a boatload of JSON data). My ajax call is: $.ajax({ url: 'http://search.twitter.com/search.json?q='+searchTerm, dataType: 'json', async: true, beforeSend: function(request) { window.console.log('starting AJAX request to get Twitter data'); }, success: function(data, textStatus, request) { window.console.log('AJAX request to get Twitter succeeded: status=' + textStatus); callback(data); }, error: function(request, status, error) { window.console.log('AJAX request to get user data --> Error: ' + status); errback(request, status, error); } }); Firebug shows Response headers: Date Sun, 11 Apr 2010 22:30:26 GMT Server hi Status 200 OK X-Served-From b021 X-Runtime 0.23841 Content-Type application/json; charset=utf-8 X-Served-By sjc1o024.prod.twitter.com X-Timeline-Cache-Hit Miss Cache-Control max-age=15, must-revalidate, max-age=300 Expires Sun, 11 Apr 2010 22:35:26 GMT Vary Accept-Encoding X-Varnish 1827846877 Age 0 Via 1.1 varnish X-Cache-Svr sjc1o024.prod.twitter.com X-Cache MISS Content-Encoding gzip Content-Length 2126 Connection close The HTTP status is OK (200), the Conetnt-Type is properly application/json, and the Content-Length of 2126 (gzip'd) implies data came back. Yet Firebug shows the Response to be empty, and a test of the supplied data shows it o be 'null.' I am aware of a similar post on Stack Overflow: http://stackoverflow.com/questions/1188976/jquery-get-function-succeeds-with-200-but-returns-no-content-in-firefox and from that would assume this problem is possibly related to cross-domain security, but... I know there are many JS widgets and whatnots that ajax get data from Twitter. Is there something I need to enable to allow this?

    Read the article

  • rubygem Twitter4R Issues

    - by Leonardo Dario Perna
    Hi everyone, I'm trying to get started with twitter4r but I'm having some issues: Why I can't load the gem in IRB? $ sudo gem install twitter4r Successfully installed twitter4r-0.3.2 1 gem installed Installing ri documentation for twitter4r-0.3.2... Installing RDoc documentation for twitter4r-0.3.2... $ irb require 'rubygems' = false require 'twitter4r' LoadError: no such file to load -- twitter4r from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem_original_require' from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require' from (irb):2 I've downloaded the http://files.rubyforge.vm.bytemark.co.uk/twitter4r/twitter4rails.post-0_2_4.zip app and it works only with twitter4r-0.2.4 and NOT with last version twitter4r-0.3.2: $ script/server ./script/../config/boot.rb:26:Warning: Gem::SourceIndex#search support for String patterns is deprecated, use #find_name = Booting Mongrel (use 'script/server webrick' to force WEBrick) = Rails application starting on http://0.0.0.0:3000 = Call with -d to detach = Ctrl-C to shutdown server ** Starting Mongrel listening at 0.0.0.0:3000 ** Starting Rails with development environment... Exiting /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem_original_require': no such file to load -- twitter/rails (MissingSourceFile) from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ dependencies.rb:495:in `require' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ dependencies.rb:342:in `new_constants_in' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ dependencies.rb:495:in `require' from /Users/leonardodarioperna/Projects/Kaaaki/marrakaaaki/ twitter4rails.post-0_2_4/config/environment.rb:64 from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem_original_require' from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ dependencies.rb:495:in `require' ... 23 levels... from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem_original_require' from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require' from script/server:3 Last thing, in the /config/environment.rb I need to specify: RAILS_GEM_VERSION = '1.2.3' unless defined? RAILS_GEM_VERSION if I use my last rails version: RAILS_GEM_VERSION = '2.3.4' unless defined? RAILS_GEM_VERSION I get this error: $ script/server -p3002 = Booting Mongrel = Rails 2.3.4 application starting on http://0.0.0.0:3000 /Library/Ruby/Site/1.8/rubygems.rb:280:in `activate': can't activate activerecord (= 1.15.6, runtime) for [], already activated activerecord-2.3.4 for ["rails-2.3.4"] (Gem::LoadError) from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:35:in `require' from /Library/Ruby/Gems/1.8/gems/activesupport-2.3.4/lib/ active_support/dependencies.rb:156:in `require' from /Library/Ruby/Gems/1.8/gems/activesupport-2.3.4/lib/ active_support/dependencies.rb:521:in `new_constants_in' from /Library/Ruby/Gems/1.8/gems/activesupport-2.3.4/lib/ active_support/dependencies.rb:156:in `require' from /Library/Ruby/Gems/1.8/gems/twitter4r-0.2.4/lib/twitter/rails.rb: 6 from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem_original_require' from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require' from /Library/Ruby/Gems/1.8/gems/activesupport-2.3.4/lib/ active_support/dependencies.rb:156:in `require' ... 8 levels... from /Library/Ruby/Gems/1.8/gems/rails-2.3.4/lib/commands/server.rb: 84 from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem_original_require' from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require' from script/server:3 And that's all :-) Thank you!

    Read the article

  • Use the Twitter API to run a script every time I post a new tweet

    - by Mathias Bynens
    I have a PHP script on my server that I want to run every time I post a new tweet to Twitter. Is there a way to automate this? I could of course set up a cron job to run the script every five minutes, or run the script manually every time after tweeting, but neither of those is instant — and that’s exactly what I’m looking for. Is it possible to use the Twitter API to run a script / get a URL every time my timeline is updated?

    Read the article

  • How do you update your twitter status using YQL?

    - by waterfallrain
    This is the code example I am following: VALUES ('tweeting from yql!', '@your_consumer_key', '@your_consumer_secret', '@your_access_token', '@your_access_secret'); I understand the consumer key and secret part however I dont understand what to put in for the your_access_token and your_access_secret part. Are these urls I was given what I need to add for the last two items? http://twitter.com/oauth/request_token

    Read the article

  • Struts2 ParametersInterceptor problem with oauth_token

    - by Tahir Akram
    I am developing an application in Struts2 with Twitter4J at GAE/J. I am getting following exception in the GAE log. Unable to understand whats wrong with it. com.opensymphony.xwork2.interceptor.ParametersInterceptor setParameters: ParametersInterceptor - [setParameters]: Unexpected Exception caught setting 'oauth_token' on 'class com.action.Home: Error setting expression 'oauth_token' with value '[Ljava.lang.String;@146ac5a' Following is my struts.xml <!DOCTYPE struts PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 2.0//EN" "http://struts.apache.org/dtds/struts-2.0.dtd" <constant name="struts.enable.DynamicMethodInvocation" value="false" /> <constant name="struts.devMode" value="false" /> <package name="hello" extends="struts-default" > <action name="Home" class="com.action.Home"> <result name="SUCCESS">/home.jsp</result> <result name="ERROR">/message.jsp</result> </action> </package> Home.java code Twitter twitter = new Twitter(); HttpSession session = request.getSession(); twitter.setOAuthConsumer(FFConstants.CONSUMER_KEY, FFConstants.CONSUMER_SECRET); AccessToken accessToken = twitter.getOAuthAccessToken((String)session.getAttribute("token"), (String)session.getAttribute("tokenSecret")); twitter.setOAuthAccessToken(accessToken); User user = twitter.verifyCredentials(); It will be great if some one give me pointer on it. Thanks.

    Read the article

  • twitter API problem

    - by Gabri
    I am using this to get my latest Tweets <script type="text/javascript" src="http://twitter.com/javascripts/blogger.js" ></script> <script type="text/javascript"src="http://twitter.com/statuses/user_timeline/username.json?callback=twitterCallback2&amp;count=2"></script> so i have to get the latest 2 tweets cause i set the count to 2 , sometimes it returns only 1 why is that ?

    Read the article

  • How does the Twitter rate limit API work with multiple accounts?

    - by dfrankow
    I know there's a Rest API to check the Twitter rate limit. To summarize policy: 150 for an IP, and 150 per non-whitelisted account except for searches (which are IP only). However, my app is using Twython, authenticated, but the limit seems to decrease for both my accounts as I use it. Example: No authentication: $ wget http://api.twitter.com/1/account/rate_limit_status.xml -O - <?xml version="1.0" encoding="UTF-8"?> <hash> <hourly-limit type="integer">150</hourly-limit> <reset-time-in-seconds type="integer">1266968961</reset-time-in-seconds> <reset-time type="datetime">2010-02-23T23:49:21+00:00</reset-time> <remaining-hits type="integer">134</remaining-hits> </hash> Authentication with account #1: $ wget --user b... --password=youwish http://api.twitter.com/1/account/rate_limit_status.xml -O - <?xml version="1.0" encoding="UTF-8"?> <hash> <reset-time-in-seconds type="integer">1266968961</reset-time-in-seconds> <reset-time type="datetime">2010-02-23T23:49:21+00:00</reset-time> <remaining-hits type="integer">134</remaining-hits> <hourly-limit type="integer">150</hourly-limit> </hash> Authentication with account #2: $ wget --user d... --password=youwish http://api.twitter.com/1/account/rate_limit_status.xml -O - <?xml version="1.0" encoding="UTF-8"?> <hash> <reset-time type="datetime">2010-02-23T23:49:21+00:00</reset-time> <remaining-hits type="integer">134</remaining-hits> <hourly-limit type="integer">150</hourly-limit> <reset-time-in-seconds type="integer">1266968961</reset-time-in-seconds> </hash> You see how both accounts seem to have exactly the same rate limit info (134/150)? I only used one account in my app, so why do both accounts show decrease?

    Read the article

  • Twitter mood API

    - by user220755
    Is there a twitter API that returns mood? I have seen some websites that return the mood of a specific tweet and I want to be able to use an API (or to use some open source code) to get the mood of a tweet, does anyone know if there is an easy way to do that or if there is an already built API for this?

    Read the article

  • wait for CLLocationManager to finish before tweeting

    - by user295944
    I want to wait for latitude.text and longtitude.text to be filled in before sending a tweet, this code works fine, but I would rather not put the tweeting part in locationManager because I also want to sometimes update the current location without sending a tweet. How can I make sure the txt gets filled in before sending the tweet without doing this? - (IBAction)update { latitude.text =@""; longitude.text =@""; locmanager = [[CLLocationManager alloc] init]; [locmanager setDelegate:self]; [locmanager setDesiredAccuracy:kCLLocationAccuracyBest]; [locmanager startUpdatingLocation]; } - (void)locationManager:(CLLocationManager *)manager didUpdateToLocation:(CLLocation *)newLocation fromLocation:(CLLocation *)oldLocation { CLLocationCoordinate2D location = [newLocation coordinate]; latitude.text = [NSString stringWithFormat: @"%f", location.latitude]; longitude.text = [NSString stringWithFormat: @"%f", location.longitude]; TwitterRequest * t = [[TwitterRequest alloc] init]; t.username = @"****"; t.password = @"****"; [twitterMessageText resignFirstResponder]; loadingActionSheet = [[UIActionSheet alloc] initWithTitle:@"Posting To Twitter..." delegate:nil cancelButtonTitle:nil destructiveButtonTitle:nil otherButtonTitles:nil]; [loadingActionSheet showInView:self.view]; [t statuses_update:twitterMessageText.text andLat:latitude.text andLong:longitude.text delegate:self requestSelector:@selector(status_updateCallback:)]; twitterMessageText.text=@""; }

    Read the article

  • Codeigniter Twitter Library : What is my Callback URL. Where can i find it?

    - by Tapha
    I would like to know where i can find my callback url in ci? Im quite new to it so not really sure. Here is the lib im using. <?php class Home extends Controller { function Home() { parent::Controller(); } public function index() { // This is how we do a basic auth: // $this->twitter->auth('user', 'password'); // Fill in your twitter oauth client keys here $consumer_key = ''; $consumer_key_secret = ''; // For this example, we're going to get and save our access_token and access_token_secret // in session data, but you might want to use a database instead :) $this->load->library('session'); $tokens['access_token'] = NULL; $tokens['access_token_secret'] = NULL; // GET THE ACCESS TOKENS $oauth_tokens = $this->session->userdata('twitter_oauth_tokens'); if ( $oauth_tokens !== FALSE ) $tokens = $oauth_tokens; $this->load->library('twitter'); $auth = $this->twitter->oauth($consumer_key, $consumer_key_secret, $tokens['access_token'], $tokens['access_token_secret']); if ( isset($auth['access_token']) && isset($auth['access_token_secret']) ) { // SAVE THE ACCESS TOKENS $this->session->set_userdata('twitter_oauth_tokens', $auth); if ( isset($_GET['oauth_token']) ) { $uri = $_SERVER['REQUEST_URI']; $parts = explode('?', $uri); // Now we redirect the user since we've saved their stuff! header('Location: '.$parts[0]); return; } } // This is where you can call a method. $this->twitter->call('statuses/update', array('status' => 'Testing CI Twitter oAuth sexyness by @elliothaughin')); // Here's the calls you can make now. // Sexy! /* $this->twitter->call('statuses/friends_timeline'); $this->twitter->search('search', array('q' => 'elliot')); $this->twitter->search('trends'); $this->twitter->search('trends/current'); $this->twitter->search('trends/daily'); $this->twitter->search('trends/weekly'); $this->twitter->call('statuses/public_timeline'); $this->twitter->call('statuses/friends_timeline'); $this->twitter->call('statuses/user_timeline'); $this->twitter->call('statuses/show', array('id' => 1234)); $this->twitter->call('direct_messages'); $this->twitter->call('statuses/update', array('status' => 'If this tweet appears, oAuth is working!')); $this->twitter->call('statuses/destroy', array('id' => 1234)); $this->twitter->call('users/show', array('id' => 'elliothaughin')); $this->twitter->call('statuses/friends', array('id' => 'elliothaughin')); $this->twitter->call('statuses/followers', array('id' => 'elliothaughin')); $this->twitter->call('direct_messages'); $this->twitter->call('direct_messages/sent'); $this->twitter->call('direct_messages/new', array('user' => 'jamierumbelow', 'text' => 'This is a library test. Ignore')); $this->twitter->call('direct_messages/destroy', array('id' => 123)); $this->twitter->call('friendships/create', array('id' => 'elliothaughin')); $this->twitter->call('friendships/destroy', array('id' => 123)); $this->twitter->call('friendships/exists', array('user_a' => 'elliothaughin', 'user_b' => 'jamierumbelow')); $this->twitter->call('account/verify_credentials'); $this->twitter->call('account/rate_limit_status'); $this->twitter->call('account/rate_limit_status'); $this->twitter->call('account/update_delivery_device', array('device' => 'none')); $this->twitter->call('account/update_profile_colors', array('profile_text_color' => '666666')); $this->twitter->call('help/test'); */ } } /* End of file welcome.php */ /* Location: ./system/application/controllers/home.php */ Thank you all

    Read the article

  • How would i access the properties in this object? Twitter API

    - by Tapha
    I have stores this object in an variable called results. How would i access the profile_image_url for example. Here is the return value with print_r: stdClass Object ( [results] => Array ( [0] => stdClass Object ( [profile_image_url] => http://a3.twimg.com/profile_images/685278639/twitter-logo_normal.jpg [created_at] => Mon, 10 May 2010 11:29:44 +0000 [from_user] => BarclaysWealth [metadata] => stdClass Object ( [result_type] => recent ) [to_user_id] => [text] => RT @BarclaysStock: Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7 [id] => 13721505359 [from_user_id] => 14895786 [geo] => [iso_language_code] => en [source] => <a href="http://twitter.com/">web</a> ) [1] => stdClass Object ( [profile_image_url] => http://a1.twimg.com/profile_images/671523082/32fb0a8_normal.jpg [created_at] => Fri, 07 May 2010 21:02:10 +0000 [from_user] => InfoFocus [metadata] => stdClass Object ( [result_type] => recent ) [to_user_id] => [text] => RT @BarclaysWealth: RT @BarclaysStock: Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7 [id] => 13569384857 [from_user_id] => 85742792 [geo] => [iso_language_code] => en [source] => <a href="http://www.hootsuite.com" rel="nofollow">HootSuite</a> ) [2] => stdClass Object ( [profile_image_url] => http://a3.twimg.com/profile_images/685278639/twitter-logo_normal.jpg [created_at] => Fri, 07 May 2010 20:59:20 +0000 [from_user] => BarclaysWealth [metadata] => stdClass Object ( [result_type] => recent ) [to_user_id] => [text] => RT @BarclaysStock: Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7 [id] => 13569257933 [from_user_id] => 14895786 [geo] => [iso_language_code] => en [source] => <a href="http://www.hootsuite.com" rel="nofollow">HootSuite</a> ) [3] => stdClass Object ( [profile_image_url] => http://a1.twimg.com/profile_images/485934856/BD_Icon_Twitter_small_normal.gif [created_at] => Fri, 07 May 2010 16:35:56 +0000 [from_user] => BARXdirect [metadata] => stdClass Object ( [result_type] => recent ) [to_user_id] => [text] => RT @BarclaysStock: Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7 [id] => 13557670463 [from_user_id] => 66715243 [geo] => [iso_language_code] => en [source] => <a href="http://twitter.com/">web</a> ) [4] => stdClass Object ( [profile_image_url] => http://a1.twimg.com/profile_images/431590520/BSL_icon_normal.gif [created_at] => Fri, 07 May 2010 16:35:12 +0000 [from_user] => BarclaysStock [metadata] => stdClass Object ( [result_type] => recent ) [to_user_id] => [text] => Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7 [id] => 13557633799 [from_user_id] => 36238006 [geo] => [iso_language_code] => en [source] => <a href="http://twitter.com/">web</a> ) ) [max_id] => 13722716932 [since_id] => 0 [refresh_url] => ?since_id=13722716932&q=http%3A%2F%2Fbit.ly%2FOaYh7 [results_per_page] => 15 [page] => 1 [completed_in] => 0.026887 [query] => http%3A%2F%2Fbit.ly%2FOaYh7 )

    Read the article

  • Problem with printing output using PHP library

    - by Jack
    I am using the PHP library tools on a we hosting service( with cURL enabled). I have so far tried 2 tools but I cant get the output of my code to print to the screen. http://github.com/jdp/twitterlibphp - PHP library Sample code - <?php require("twitter.lib.php"); $twitter = new Twitter("xxxx", "xxxxx"); $public_timeline = $twitter->getPublicTimeline(); echo'<pre>'; print_r( $public_timeline ); echo'</pre>'; ?> I don't get any output. What can be the problem? Do I need to install any modules or packages? Please Help

    Read the article

  • Trying to parse twitter trends

    - by timothy5216
    Im trying to parse twitter trends but i keep getting a parser error at "as_of". anyone know why this is happening? EDIT: Here is the code im using NSMutableArray *tweets; tweets = [[NSMutableArray alloc] init]; NSURL *url = [NSURL URLWithString:@"http://search.twitter.com/trends/current.json"]; trendsArray = [[NSMutableArray alloc] initWithArray:[CCJSONParser objectFromJSON:[NSString stringWithContentsOfURL:url encoding:4 error:nil]]]; NSMutableDictionary *dict = [[NSMutableDictionary alloc] init]; for (int i = 0; i < [trendsArray count]; i++) { dict = [[NSMutableDictionary alloc] init]; //[post setObject: [[currentArray objectAtIndex:i] objectForKey:@"query"]]; [dict setObject:[trendsArray objectAtIndex:i] forKey:@"trends"]; //[dict setObject:[trendsArray objectAtIndex:i] forKey:@"query"]; //[post setObject:[trendsArray objectAtIndex:i] forKey:@"as_of"]; [tweets addObject:dict]; //post = nil; }

    Read the article

  • How to crawl retweets of a certain user?

    - by Xiong
    I studied the Twitter API Documentation today. Only find that we could use "Twitter REST API Method: statuses user_timeline" to acquire statuses of a certain user. Retweets are stripped out of the user_timeline for backwards compatibility reasons. If I want retweets included, API Documentation recommend "statuses retweeted_by_me", but retweeted_by_me cannot return the retweets by other users. I think maybe we can analyse the twitter webpage of a certain user to get his retweets. However is there any elegant way to crawl retweets of a certain user? Thanks in advance!

    Read the article

  • How do I tweet, using the DotNetOpenAuth library?

    - by MedicineMan
    I just downloaded the DotNetOpenAuth library and ran the AuthConsumer demo. It is an excellent library so far! Everything worked as advertised, which has not been my experience with a lot of Facebook and Twitter sample code that I have been working with recently. What I am trying to figure out is: How do I tweet using this library? I am currently planning to implement this in ASP MVC, but my initial thoughts is that the presentation platform doesn't matter all that much at the level I'm looking at.

    Read the article

1 2 3 4  | Next Page >