Created
April 20, 2015 06:27
-
-
Save mikestratton/27504c08884c435e0341 to your computer and use it in GitHub Desktop.
Connect & tweet to twitter using TwitterOAuth & Composer!
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//Use the force, Luke: https://twitteroauth.com/ | |
require "vendor/autoload.php"; | |
use Abraham\TwitterOAuth\TwitterOAuth; | |
$twitterConnection = new TwitterOAuth( | |
'', //Consumer Key | |
'', //Consumer secret | |
'', //Access token | |
'' //Access token secret | |
); | |
$content = $twitterConnection->get('account/verify_credentials'); | |
$twitterConnection->post('statuses/update', array('status' => "14")); | |
echo $twitterConnection->http_post; | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment